The Deflated Sharpe Ratio and Backtest Overfitting
How the Deflated Sharpe Ratio corrects for multiple testing, skew and kurtosis, and how it relates to the probability of backtest overfitting.
Published 2026-10-11 · Educational explainer, not investment advice
Selection bias under multiple testing
If you try enough strategy variants, the best one will show a high Sharpe ratio by chance alone. Reporting only that winner without the number of trials is the most common source of false discoveries in quantitative research.
Deflating the Sharpe ratio
The Deflated Sharpe Ratio (DSR) is the probability that the true Sharpe exceeds the maximum Sharpe expected from N independent trials, adjusting for sample length, skewness and kurtosis of returns.
from scipy.stats import normimport numpy as npdef expected_max_sr(sr_var, n_trials): g = 0.5772156649 return np.sqrt(sr_var) * ((1 - g) * norm.ppf(1 - 1 / n_trials) + g * norm.ppf(1 - 1 / (n_trials * np.e)))def deflated_sr(sr, sr_var, n_trials, T, skew, kurt): sr0 = expected_max_sr(sr_var, n_trials) denom = np.sqrt(1 - skew * sr + (kurt - 1) / 4 * sr**2) return norm.cdf((sr - sr0) * np.sqrt(T - 1) / denom)Probability of backtest overfitting
Combinatorially symmetric cross-validation estimates how often the in-sample best configuration underperforms the median out of sample. Together with DSR it gives reviewers a quantitative view of how much a result depends on search.
Source: López de Prado, M. (2018). Advances in Financial Machine Learning. Wiley. Chapters 11–14; Bailey & López de Prado (2014), The Deflated Sharpe Ratio.
Run this method as part of a structured research workflow.
Open Voltacent Agent