Fama Beta
The Fama Beta is the Beta the asset would have if it moved perfectly with the benchmark: its total risk in units of market risk. Fama (1972) used it to split a portfolio’s return for selectivity into net selectivity and the return the portfolio needs for being undiversified.
The formula for the Fama Beta is as follows:
\[\text{Beta}_{\text{Fama}} = \frac{\sigma_{a}}{\sigma_{m}}\]Where \(\sigma_{a}\) and \(\sigma_{m}\) are the standard deviations of the asset and benchmark returns over the same dates. It equals the Ordinary Least Squares Beta divided by the correlation of the two, so it is never below the absolute value of that Beta and is far above it for an asset with a low correlation to the market.
Beta is the slope of an asset’s returns on those of the market: the part of its risk that comes from moving with the market as a whole. In the Capital Asset Pricing Model (CAPM) of Sharpe, Lintner and Mossin this is the only risk that earns a premium, because the rest disappears in a diversified portfolio, so Beta sets the return investors require and enters the cost of equity. The market is the benchmark, typically a broad index such as the S&P 500.
Beta is read against 1, the benchmark’s own Beta: above 1 the asset tends to amplify market moves, below 1 to dampen them, and a negative Beta means it tends to move against the market. A Beta close to zero can come from a low correlation with the market rather than from low volatility, so it is worth checking both before calling a stock defensive. Every estimate rests on a sample of returns and moves from one window to the next, which is why the estimators differ in how they deal with estimation noise, late reactions to the market and asymmetry between rising and falling markets.
See definition: Beta (finance) (Wikipedia)
Also known as: total risk Beta, Fama’s beta.
In the Finance Toolkit this is get_beta with method="fama", the same function as Beta.
Example · NVDA, TSLA, JPM · 2021 to 2025
Install the Finance Toolkit with pip install financetoolkit -U, then call get_beta:
from financetoolkit import Toolkit
toolkit = Toolkit(
["NVDA", "TSLA", "JPM"],
api_key="FINANCIAL_MODELING_PREP_KEY",
start_date="2021-01-01",
end_date="2025-12-31",
)
toolkit.performance.get_beta(method="fama")
| Parameter | Type | Description | Example |
|---|---|---|---|
period | str | The period to use for the calculation. Options are: “daily”, “weekly”, “monthly”, “quarterly”, “yearly”. Defaults to “quarterly” if the Toolkit is initialised with quarterly=True, otherwise “yearly”. | "quarterly" |
rolling | int | The rolling window size to use for the calculation. If you select period = ‘monthly’ and set rolling to 12 you obtain the rolling 12-month Beta. At least 2. Defaults to None. | 4 |
method | str | The estimator of the Beta. Options are: “ols” (Ordinary Least Squares Beta, the covariance over the benchmark variance), “blume” (Blume Adjusted Beta, pulled a third of the way towards 1), “vasicek” (Vasicek Beta, shrunk towards the mean Beta of the tickers), “dimson” (Dimson Beta, the sum of the lagged, same and leading slopes), “scholes_williams” (Scholes-Williams Beta, three slopes over the benchmark autocorrelation), “upside” (Upside Beta, the periods the benchmark rose), “downside” (Downside Beta, the periods the benchmark fell), “frazzini_pedersen” (Frazzini-Pedersen Beta, at the end of each period), “fama” (Fama Beta, the ratio of the standard deviations). Defaults to “ols”. | "ols" |
lags | int | The number of leads and lags of the Dimson Beta. Defaults to 1. | 2 |
rounding | int | None | The number of decimals to round the results to. Defaults to None, which uses the rounding of the Toolkit (4 unless set otherwise). | 2 |
growth | bool | Whether to calculate the growth of the ratios. Defaults to False. | True |
lag | int | list[int] | The lag to use for the growth calculation. Defaults to 1. | 4 |
standardize | bool | Whether to standardize (Z-Score) the result. When combined with growth=True, standardizes the growth values instead of the raw values. Defaults to False. | True |
transform | str | list[str] | None | Time series steps applied in order, such as “sma:12” (moving average), “ema:12”, “std:12”, “zscore:60”, “percentile:120”, “yoy”, “pct_change:3,annualize:3”, “log”, “diff”, “cumsum” or “hp_trend” and “hp_cycle” (Hodrick-Prescott), before growth. A window needs that many periods of history, so the first periods can be empty. Defaults to None. | None |
show_columns | str | list[str] | None | The columns to keep, a name or a list of names, matched on every column level, or the rows when no column has those names (such as the line items of a financial statement). Names that do not exist are logged, and when none exist the result is returned in full. Defaults to None, which keeps every column. | None, which keeps every column |
Which returns:
| Date | NVDA | TSLA | JPM |
|---|---|---|---|
| 2021 | 3.4861 | 4.2357 | 1.6535 |
| 2022 | 2.6071 | 2.7503 | 1.2323 |
| 2023 | 3.7013 | 4.1338 | 1.5866 |
| 2024 | 4.1772 | 5.0518 | 1.8691 |
| 2025 | 2.5462 | 3.2581 | 1.2752 |
5 rows
References
- Paper Fama, E.F. (1972). “Components of Investment Performance.” Journal of Finance, 27(3), 551-567.
- Paper Bacon, C.R. (2008). “Practical Portfolio Performance Measurement and Attribution.” 2nd edition, John Wiley & Sons.