Ret1yr% vs ln(close(0)/fhist("close(0)",52)

These two formulae output the 1 year return of a ticker.

ret1yr% is based on bars (and includes dividends), and ln(close(0)/fhist(“close(0)”,52) based on weeks (not sure if includes dividends).

They are fairly close, but for some tickers there can be a notable spread.

There may be some difference due to bars vs weeks, but should be minor only, still some spread.

Can someone confirm if the “fhist” version excludes dividends? Any other differences? In share count?

Thanks!
Ryan

There’s no reason to use FHist(“Close(0)”,52) when you can use Close(252) or Close_D(260). The operations, though, are quite different. FHist is unadjusted for splits and dividends, while Close is fully adjusted for both. I’m also unsure why you’re including ln.

1 Like

FHist has been safe to use with splits & dividends FHist now safe to use with split sensitive factors. But as Yuval said not sure there’s a reason to use FHist

You can see that it works for TSLA and for MRBK which pays dividends. Just set the as-of date to 5/14/2023 to align it to the weeked.

SplitFactor(300)>=2
Ticker(“tsla mrbk”)
@fh:fhist(“close(0)”,52)
@cl:close(250)

Thx - after posting this I realized I could use close(251) instead of the fhist.

Essentially ret1yr% is the same as (close(0)-close(251))/close(251), which is split adjusted and includes dividends.

I also stumbled on closeexdiv(bars), which excludes dividends.

Some further background - I’m trying to replicate some of the work in OSAM’s “Factors from Scratch” paper. There’s a breakdown of returns, which requires taking logarithmic returns, hence the ln.

Hope to write a piece on SA on “return decomposition” soon.

Cheers,
Ryan