This is a strategy optimised into uselessness, posted as an exhibit rather than a recommendation.
It is what overfitting looks like when it is written down.
1. The exhibit
# BUY — eleven conditions, four trades a month, none of them good live
if HhmmSs >= 94500 and HhmmSs <= 103000:
if ChangeAngle(60) > 47 and Strength > 128 and AvgStrength(300) > 118:
if DayAmount > 8000000 and Volatility(600) > 0.8 and Volatility(600) < 2.2:
if SumBuyVol(120) > SumSellVol(120) * 1.7 and RisingStreak(8):
Buy()
Every number here was tuned to fit four specific trades in the test period. It backtested
beautifully. Live it took two trades in two months and lost on both.
2. The numbers that give it away
| Condition | The tell |
|---|
ChangeAngle(60) > 47 | 47, not 45 or 50 — a threshold that precise came from a fit, not from a reason |
Volatility(600) > 0.8 and < 2.2 | a two-sided band with both edges tuned |
RisingStreak(8) | eight consecutive rises is a very specific shape |
AvgStrength(300) > 118 | a second strength condition doing almost the same job as the first |
None of these is wrong on its own. Together they describe a handful of days rather than a market.
3. The one number that would have caught it
Trade count. It fell every single time the strategy "improved".
That is the signal, and it is available while you are still optimising rather than two months
later. A change that raises your average return and cuts your trade count by half has not made the
strategy better — it has made your evidence weaker. With four trades in the sample, the confidence
interval on the result is wider than the result.
Watch trade count with the same attention you give to return, and treat any improvement that comes
with a large drop in trades as a warning rather than a win.
4. Why it looked so good
A backtest with four trades is not a measurement, it is an anecdote. Selecting eleven conditions
that all happen to be true on four profitable days is not hard — with enough parameters you can
always do it, and the search itself is what produces the illusion.
Our own model was not immune. When we audited it against live subscription constraints, 82.2% of
its fills turned out to be trades we could not have taken, and those fills carried 48% of the
profit (
82% of our backtest fills were trades we could not have taken live).
5. What to do instead
Run
the same entry at three sensitivities. If a strategy only works at exactly one
setting of each threshold, it found your sample. If it degrades smoothly as you loosen it, there is
something behind it.
And compare against
the baseline your trading strategy has to beat rather than against
the previous version of itself. Optimising against your own last attempt is how you get here.
Educational template for research and backtesting. Not investment advice and not a signal service.