sf_quant.performance.generate_ic_chart#
- sf_quant.performance.generate_ic_chart(ics: ICSchema, title: str | None = None, ic_type: str | None = None, file_name: str | None = None) None#
Plot cumulative Information Coefficient (IC) over time.
This function generates a line chart of the cumulative sum of IC values across dates. The cumulative IC provides insight into the persistent predictive power of alphas by showing whether ICs compound positively or negatively over time.
Parameters#
- ics (ICSchema): A DataFrame containing IC values.
Must include the following columns: -
date(date): The observation date. -ic(float): The IC value for that date.- title (str | None, optional): The chart’s main title. Defaults to
'Cumulative Information Coefficient'if not provided.- ic_type (str | None, optional): Type of IC to display (e.g., ‘Pearson’ or ‘Rank’).
If not provided, defaults to ‘Rank IC’.
- file_name (str | None, optional): If not
None, saves the chart to the given file path. Otherwise, the chart is displayed interactively.
Returns#
None: Displays the cumulative IC time series chart using Matplotlib and Seaborn, or saves it to a file if
file_nameis specified.Notes#
The cumulative IC is computed using a simple cumulative sum (no compounding).
A rising line indicates consistent positive ICs, while a declining line indicates persistent negative ICs.
Useful for assessing whether a signal’s predictive strength holds over time.