How to read backtest results: a step-by-step guide
By Oalgo · Last reviewed
To read backtest results, start with the number of trades and the date range, then the drawdown, then the fees. The end result comes last, because one lucky trade can change it.
A backtest report is a set of numbers about simulated trades on past prices. Each number answers a different question, so read them together.
In what order should you read backtest results?
#| Step | Look at | Ask |
|---|---|---|
| 1 | The number of trades and the date range | Are there enough trades to say anything? A few trades cannot say much. |
| 2 | The drawdown | Could you stay with the rules through a fall that size? |
| 3 | Fees and slippage | How much of each trade do the costs take? Rules that trade often pay more of both. |
| 4 | Another date range | Do the rules look the same on a different stretch? Then forward test them. |
| 5 | The end result | How much of it came from a few trades? |
What do the numbers in a backtest report mean?
#| Number | What it tells you |
|---|---|
| Trades | How many times the rules entered and exited. |
| Win rate | The share of trades that ended above their starting value, after fees and slippage. A trade that ends exactly at its starting value is not a win. |
| Drawdown | The largest fall, in percent, from a high point of the account value to a later low point. It shows the worst stretch the rules went through. The drawdown recovery calculator shows the gain needed to recover from a fall. |
| Fees | What the trades would have cost in fees. They are already taken off each trade. The fee calculator shows what fees cost in and out. |
| Slippage | The small difference between the price the rules saw and the price the test fills at. The test counts it as a cost. |
| Sharpe ratio | The average daily change in account value compared with how much those daily changes vary, scaled to a year. A steadier line scores higher. |
What does a worked example look like?
#Two made-up reports. Neither shows a result, only what you can read from the trade count and the date range.
| Report A | Report B | |
|---|---|---|
| Number of trades | 6 | 140 |
| Date range | 3 weeks | 18 months |
| Share of the trades that one trade is | About 17% | Under 1% |
| What it can show | Little. One trade moves the whole report, and 3 weeks is one kind of market. | More. One trade barely moves it, and 18 months spans several kinds of market. |
Report A is not ready to read past step 1. Report B is worth reading on, at the drawdown and the fees. The trade count guide explains how many trades it takes.
What does a report not show?
#A report describes the past. It does not say how the rules will behave on new prices. Rules tuned too closely to one period (overfitting) can look good in a report and behave differently later.
In Oalgo, the Analytics tab of a finished run goes past these numbers. Its Risk view has cards named Did It Hold Up? and Result Concentration.
Read next
- What is backtesting?Backtesting runs your rules on past prices to see how they would have behaved. Learn what it shows, what it cannot show, and how to read the report.
- What is overfitting?Overfitting is tuning rules so closely to past prices that they stop working on new ones. Learn why it fools people and how to check for it.