Deflated Sharpe Ratio
The Deflated Sharpe Ratio (DSR) is the probability that a strategy's true Sharpe ratio is above what the best of everything you tried would be expected to show with no edge at all. It was published by David Bailey and Marcos López de Prado in 2014.
Why a Sharpe ratio alone is not enough
Selection. Test 100 ideas with no edge and the best one still looks good, because it was picked for looking good. The more you try, the higher the bar should be.
Short and uneven records. A Sharpe ratio from 60 trades is far less certain than the same number from 600. Rare large losses (negative skew, fat tails) make it less certain still.
The formula
SR0 = sqrt(V) × [ (1 − g) × Z⁻¹(1 − 1/N) + g × Z⁻¹(1 − 1/(N e)) ] DSR = Z[ (SR − SR0) × sqrt(T − 1) / sqrt(1 − skew × SR + (kurt − 1)/4 × SR²) ]
SR is the Sharpe ratio per period (per trade or per day, never annualized), T the number of periods, N the number of independent tries, V the variance of the Sharpe ratios across those tries, g the Euler–Mascheroni constant (0.5772), and Z the Normal distribution. Kurtosis is the raw kind: 3 for a Normal distribution.
Worked example
The paper's strategy has an annualized Sharpe ratio of 2.5 over five years of daily returns (1,250 days), with skew −3 and kurtosis 10. The annualized Sharpe ratios of the tries have a variance of 0.5. Nothing about the strategy changes down this table, only how many were tried:
| Strategies tried | Best expected with no edge (annual Sharpe) | Deflated Sharpe Ratio |
|---|---|---|
| 10 | 1.11 | 99.4% |
| 46 | 1.59 | 95.1% |
| 100 | 1.79 | 90.0% |
| 1,000 | 2.30 | 64.0% |
At 46 tries it just reaches the usual 95% line. At 100 it doesn't, and at 1,000 the same record is weak evidence.
Check your own trades
The free check on this site works the Deflated Sharpe Ratio out from a trade file, after fees, and shows how many more trades it would take to reach 95%. The file is read in your browser and never uploaded.
In Python:
pip install algobacktesting
from algobacktesting import deannualize_sharpe, deflated_sharpe_ratio
deflated_sharpe_ratio(
deannualize_sharpe(2.5, 250), 1250,
n_trials=100, sharpe_variance=0.5 / 250, skew=-3, kurtosis=10,
) # 0.9004
What it cannot tell you
- It only corrects for the tries you count. Forgotten versions make it too generous.
- It treats the tries as independent. Many near-copies of one idea count for fewer, so counting each one is strict.
- It can't see look-ahead, unrealistic fills or missing fees in the backtest itself.
- It describes the past. A real edge can stop working.
Source: Bailey and López de Prado (2014), The Deflated Sharpe Ratio, SSRN 2460551.