qis.compute_per_asset_betas

qis.compute_per_asset_betas(result, min_obs_per_asset=12, fit_intercept=False)[source]

Estimate one β per (asset, horizon) from the diagnostic pairs.

For each asset and each horizon, runs the same no-intercept (default) regression as the pooled diagnostic but restricted to that asset’s time-series of (z, r_norm_univ) pairs:

ỹ_{i,t,t+h} = β_i · z_{i,t-1} + ε

The LHS is the universe-normalised forward return (r_norm_univ) — same convention as the pooled regression, so per-asset β values are directly comparable to the pooled β.

Useful for cross-asset dispersion visualisations (e.g. boxplot of β across assets at each horizon) — a complement to the pooled and per-group regressions.

Parameters:
  • result (SignalDiagnosticsResult) – SignalDiagnosticsResult from estimate_signal_diagnostics.

  • min_obs_per_asset (int) – Minimum (z, r) pair count per asset per horizon required to report a β. Assets with fewer observations are dropped from that horizon’s row set.

  • fit_intercept (bool) – Match the corresponding flag in the pooled fit. Default False for symmetry with the pooled regression.

Returns:

Long-format DataFrame with columns [horizon, asset, asset_freq, group, beta, t_stat, n]. One row per (asset, horizon) cell that passed the min_obs_per_asset filter.

Return type:

DataFrame