InformationCoefficient<T>
Helpers & Utilities · AiDotNet.Finance.Evaluation
Information Coefficient (IC): the correlation between predicted and realized forward returns, plus its statistical significance (t-statistic, two-sided p-value) and the IC information ratio (ICIR) over a time series of per-period ICs.
For Beginners
Imagine you predict tomorrow’s stock moves for 500 stocks, then wait and see what actually happened. The IC asks: “did the stocks I was most bullish on actually go up the most?” An IC of +1 means a perfect match, 0 means no relationship (coin flip), and -1 means your predictions were exactly backwards. Because even a tiny real edge is valuable, we also compute a t-statistic and p-value to check that the IC is “really there” and not just luck. The ICIR is like a Sharpe ratio for your forecasting skill: it rewards a positive IC that shows up consistently period after period, not just on average.
How It Works
The Information Coefficient is the north-star metric of return-forecasting research: it measures how well a model’s predictions rank/track the returns that actually occurred. Both the Pearson (linear) and Spearman (rank) flavors are provided. An IC of about 0.03-0.05 that is statistically significant already represents a real, exploitable edge in liquid markets.
Methods
| Method | Summary |
|---|---|
T Pearson(IReadOnlyList<T> predicted, IReadOnlyList<T> realized) |
Pearson (linear) correlation between predicted and realized returns. |
T Spearman(IReadOnlyList<T> predicted, IReadOnlyList<T> realized) |
Spearman rank correlation: Pearson correlation of the (tie-averaged) ranks of the two series. |
ValueTuple<T, T, T> InformationRatio(IReadOnlyList<T> perPeriodIcs) |
Summarizes a time series of per-period ICs into mean IC, IC standard deviation, and the IC information ratio: ICIR = meanIC / stdIC · sqrt(periods). |
ValueTuple<T, T> Significance(T ic, int n) |
Two-sided significance test for an IC value over n observations. |