Backtesting
How a backtest can fit the past perfectly and still fail, and the ways to check it.
Overfitting (curve fitting) means tuning a strategy so closely to past data that it captures the noise of that period rather than a real edge. The more rules and settings you tweak, the better the backtest looks and the worse it usually does afterwards.
The defences: split the data, develop on one part (in-sample) and check on a part you haven't touched (out-of-sample). Walk-forward testing, set out by Robert Pardo, repeats that step through time: optimise on one window, test on the next, slide forward, and judge the strategy on the combined out-of-sample results. Forward testing (on a demo or small size) is the final check.
Put it into practice: Replay the market and test it in UNFLD's backtester →
For education only, not financial advice.