How do I calculate the three factors? The first "market" factor seems straightforward. However the SmB and the HmL factors seem to require accounting data. Also, how does one calculate the momentum factor? Can you write down explicit formulas with clearly defined notation, or provide a reference that describes the canonical calculations?
I don't have time to give you a complete, precise answer, but this may help you get going. I'm pulling stuff from various notes I have in places. It's a bit trickier than someone naively might think.
Ken French's description of their methodology:
The details section of various points in their data library has a bunch of material.
You may also look for papers where Fama and French discuss their three or five factor model. For the three factor model, you might look at "Common Risk Factors in the Returns on Stocks and Bonds," 1993, Journal of Financial Economic.
Some Compustat calculations to get you going:
- The SQL code I have to calculate book equity from the Compustat annual file is:
seq - COALESCE(pstk, 0) + COALESCE(txditc, 0) as be. (Be aware that the last part, adding back deferred taxes
txditchas a substantial effect.)
- The SQL code I used to calculate operating profitability is
(revt - cogs - COALESCE(tie,0) - COALESCE(xsga,0)) as op_numerator
- Market equity I calculate as
csho * prcc_f as me.
- The book to market ratio would then be
CASE WHEN (me is NULL) OR (me = 0) THEN NULL ELSE be /me END as beme
- Find some Compustat manual to find what those variables are.
CRSP calculations and getting the universe right...
- Limit the universe to CRSP sharecd 10 and 11.
- For breakpoint calculations, limit it to the New York Stock Exchange.
- "Rm-Rf includes all NYSE, AMEX, and NASDAQ firms. SMB and HML for July of year t to June of t+1 include all NYSE, AMEX, and NASDAQ stocks for which we have market equity data for December of t-1 and June of t, and (positive) book equity data for t-1."
Form portfolios in June based upon accounting data for the prior fiscal year. Thus the accounting data is at least six months old and possibly a year old.
I recall there may be some small, additional checks for good price data.
You can see if you're computing market equity, book equity, etc... and oper ating in the same universe of securities by checking whether you can match the percentile breakpoints they compute:
Canonical references are