quantlab.model.evaluation.information_ratio#
- quantlab.model.evaluation.information_ratio(series)[source]#
Return the mean of the finite values of
seriesover their sample std.This is the ICIR when
seriesis a per-bar IC series. NaN values (the skipped bars of an IC series) are left out rather than counted as 0. The standard deviation usesddof=1, so fewer than two finite values give NaN, and so do finite values that are all equal (tested exactly, as for the IC’s constancy test), since the ratio is then undefined.- Parameters:
- seriesarray_like
A 1-D sequence of per-bar values.
Examples
>>> information_ratio([0.1, np.nan, 0.3]) 1.4142135623730951 >>> information_ratio([0.1, np.nan]) nan