Lesson 12 of 15
Single-Factor Model
Single-Factor Model (OLS Regression)
The single-factor model explains an asset's excess return as a linear function of a single factor's excess return:
This is estimated via Ordinary Least Squares (OLS) regression.
OLS Formulas
Given two series of observations (x, y), the OLS estimates are:
where we regress excess asset returns (y) on excess factor returns (x).
Application
The factor exposure (beta) tells us how much the asset co-moves with the factor per unit of factor return. The alpha is the return unexplained by the factor.
Your Task
Implement:
factor_exposure(asset_returns, factor_returns)— OLS beta of asset returns on factor returnsfama_french_alpha(asset_returns, factor_returns, rf)— alpha from regression of excess asset returns on excess factor returns
Python runtime loading...
Loading...
Click "Run" to execute your code.