load_daily_beta_inputs

eap_pl.load_daily_beta_inputs(
    first,
    last,
    *,
    preserve_order=False,
    vintage=None,
)

Prepare the daily factors and stock observations used to estimate beta.

Shifts the market factor on the trading-day calendar before joining it to stock returns. The contemporaneous market factor is mkt_5.

Parameters

Name Type Description Default
first pl.Expr First stock-return date, inclusive, as a Polars date expression. required
last pl.Expr Last stock-return date, inclusive, as a Polars date expression. required
preserve_order bool Keep the stock-return order through the factor join. False
vintage str | int | None French archive vintage in YYYYMM format, or None for WRDS. None

Returns

Name Type Description
tuple[polars.DataFrame, polars.LazyFrame] Daily factors and a query for matched stock excess returns with finite market predictors.