Monte Carlo for Traders, Explained With a Worked Example
Your record is one path out of many. Reshuffle the same trades, or redraw them from a win rate, and see how wide the range of falls and finishes is.
Updated 4 Nov 2026 · 7 min read
On this page
A Monte Carlo test replays your trades thousands of times, in random orders or as fresh draws from your win rate, to show the range of results the same trading could have produced. Your real record is one path out of many it could have taken. The test shows how wide the others are: how deep a drawdown could have been with the same trades in another order, and how often a strategy with no edge still finishes ahead.
Two ways to run it
- Reshuffle. Keep your list of trades exactly as it is and put it in a random order. The total never changes, because the same numbers are added up. What changes is the path: how deep the worst fall is, and how long the longest losing run is.
- Redraw. Ignore the list and draw new trades from a win rate and an average win and loss. Now the total moves too, so you also see how often the same strategy finishes negative.
Both answer a question your single record cannot: how much of what you saw was the strategy, and how much was the order it happened in.
The same ten trades in three orders
You can check the idea by hand. These are made-up trades, in R (the amount risked on each): four wins of +2R and six losses of −1R, so 4 × 2 − 6 × 1 = +2R in total, whatever the order.
| Order | Trades | Total | Worst fall from a peak |
|---|---|---|---|
| As it happened | +2, −1, −1, +2, −1, +2, −1, −1, +2, −1 | +2R | 2R |
| Losses first | −1, −1, −1, −1, −1, −1, +2, +2, +2, +2 | +2R | 6R |
| Wins first | +2, +2, +2, +2, −1, −1, −1, −1, −1, −1 | +2R | 6R |
- As it happened: the running total goes 2, 1, 0, 2, 1, 3, 2, 1, 3, 2. It peaks at 2 and drops to 0, a fall of 2R; later it peaks at 3 and drops to 1, also 2R. The worst fall is 2R.
- Losses first: the total goes −1, −2 and on to −6 before the four wins bring it to +2. The start counts as the peak, so the fall is 6R.
- Wins first: it climbs to +8, then six losses take it to +2. The fall from the peak is 8 − 2 = 6R.
Same trades, same +2R, and a worst fall of 2R in one order and 6R in two others. A Monte Carlo test does this, for every order it draws, instead of three you picked.
What 20,000 reshuffles of 20 trades gave
Take a longer made-up list: 8 wins of +2R and 12 losses of −1R, so 8 × 2 − 12 = +4R every time. Put it in a random order 20,000 times and measure each order.
| Measure | Lowest | 5th percentile | Median | 95th percentile | Highest |
|---|---|---|---|---|---|
| Total | +4R in every order | ||||
| Worst fall from a peak | 2R | 3R | 5R | 7R | 11R |
The median order had a worst fall of 5R, and 28.0% of the orders fell 6R or more. The longest losing run was 4 trades in the median order, and 7 or fewer in 19 orders out of 20. The worst order possible puts all 12 losses together and falls 12R; the worst of the 20,000 random orders fell 11R. Reshuffle your own trades the same way: if your actual worst fall sits near the low end of those reshuffles, the order was kind to you; near the high end, it was not. The trades were the same either way.
What 20,000 redraws of 100 trades gave
Here the trades are drawn fresh each time from two made-up cases: one with a positive expectancy (40% wins of +2R, losses of 1R, worth +0.2R a trade) and one with none (50% wins of +1R, losses of 1R). Each run is 100 independent trades, with no costs. See expectancy for the sum behind the first, or the expectancy calculator for your own figures.
| Case | Total, 5th percentile | Median | 95th percentile | Finished below 0 | Worst fall, median | Worst fall, 95th percentile |
|---|---|---|---|---|---|---|
| 40% wins of +2R, losses of 1R | −4R | +20R | +44R | 9.2% | 10R | 19R |
| 50% wins of +1R, losses of 1R | −16R | 0R | +16R | 46.7% | 11R | 21R |
- The case with an edge lost money in 9.2% of the runs. A strategy worth +0.2R a trade finished 100 trades below zero about one time in 11, and its 5th percentile was −4R. That is the sample, not the strategy changing.
- The case with no edge finished ahead about as often as it finished behind. Its median was 0R and its 95th percentile +16R. A run of good results is not evidence of an edge on its own.
- Both had deep falls. The median worst fall was 10R with an edge and 11R without; 52.5% of the edge runs fell 10R or more at some point. Depth alone does not separate a working strategy from a lucky one.
These are made-up cases. They say nothing about any strategy you run, and they are arithmetic, not advice.
What it cannot tell you
- It assumes trades are independent. A reshuffle treats trade 7 as unrelated to trade 6. If your results come in streaks because the market does, a shuffle spreads them out and shows a gentler worst case than you lived.
- It reuses what you fed it. A list from one market in one season gives a range for that, not for the next one. Fewer than a few dozen trades makes the range itself unreliable: how many trades before your stats mean anything shows how wide that is.
- It is a range, not a forecast. “5th percentile” means one run in twenty did worse in the model. It does not mean it cannot be worse, and it says nothing about when.
- It carries your costs only if your numbers do. Use results after spread, commission and swap, or the range is too kind.
How to run a small one in a spreadsheet
- Put your trade results, in R or in money, in column A, one per row (say rows 2 to 41).
- In column B, draw a trade at random from the list:
=INDEX($A$2:$A$41, RANDBETWEEN(1, 40)). That is a redraw: the same trade can come up twice. (This draws from your own list; the earlier redraw drew from a win rate.) - In column C, a running total: C2 is
=B2, then C3 is=C2+B3, filled down. - In column D, the running peak: D2 is
=MAX(0, C2), then D3 is=MAX(D2, C3). In column E, the fall:=D2-C2. The worst fall of this run is the largest value in column E. - Recalculate (F9 in Excel; Google Sheets recalculates when you edit a cell), write down the final total and the worst fall, and repeat. By hand each repeat is a recalculation and a note; for thousands, use a short script.
To reshuffle instead, give each row a random number with =RAND() beside the trade and sort by that column, which reorders the same trades without repeating any. The risk side of the same idea has a closed form for a simple model: see risk of ruin. For the worst fall of one real stretch of trades, type its peak and trough into the drawdown calculator.
Where Trepeat is
We're working on a free journal and a backtester, with no date yet. Today Trepeat is a trade copier for MT4, MT5 and cTrader, currently on demo accounts, and you can add notes, a grade and screenshots to any copied trade once it closes, with a calendar of your results.
We do not sell a Monte Carlo tool, and the journal does not run simulations or calculate expectancy today. Its export to Excel (.xlsx) has a P&L column for each trade you have written an entry for, which can be the list the spreadsheet above starts from. The journal documentation says what it holds.
Related: maximum drawdown, the gain needed after a loss and backtesting mistakes.
Written by the Trepeat team.