quantlab.factor.predefined.fundamental_alpha.FundamentalAlpha#
- class quantlab.factor.predefined.fundamental_alpha.FundamentalAlpha(config)[source]#
Bases:
FactorKunQuantCompute the twenty-three fundamental, 13F and insider characteristics in KunQuant.
Only the selected
factor_namesare built, anddata_columnsmust name exactlyFundamentalAlphaParameters.required_panel_columnsof them. The outputs are raw characteristics, or their cross-sectional ranks withranked=True, which is whatNeutralizedFactorshould wrap.warmup_barsshould cover the longest lag: about63 * (sue_quarters + 1)bars for a SUE (600 by default),issuance_windowfor the issuance, 260 for the year-ago reports.- Parameters:
- configFactorConfig
modemust be"batch".
- Raises:
- ValueError
If an output is unknown,
data_columnsdoes not match the outputs, orkwargsis invalid.
Examples
panelmerges SEP, DAILY, SF1 ART, SF3A holdings and SF2 insiders (BadPrintMaskedDataset([sep, daily, art, holdings, insiders])):names = ("accruals", "f_score") factor = FundamentalAlpha(FactorConfig( warmup_bars=600, dataset=panel, mode="batch", factor_names=names, data_columns=FundamentalAlphaParameters().required_panel_columns(names), )) factor.compute("2010-01-04", "2010-12-31")["f_score"].max().item() # 9.0