FRENESDE

Monte Carlo simulation

A backtest shows only one path: the order in which the trades happened. Monte Carlo simulation replays your trades thousands of times in random order (or by drawing them at random with replacement) to see the range of possible paths.
With the same trades the final result does not change, but the drawdown changes a lot depending on whether losses come bunched or spread out. Your backtest may have been lucky in the order of trades.
Doable in a spreadsheet: a column of results in R, a random function to shuffle them, the equity curve and its maximum drawdown; copy it 1,000 times. Streak calculation: with 60% losers, the probability that 8 given trades all lose is 0.6⁸ ≈ 1.7%; over hundreds of trades, such a streak eventually happens.
Read the percentiles: if 95% of simulations have a maximum drawdown below 25%, plan for at least 25%, even if the backtest showed 14%. Limit: Monte Carlo only shuffles past trades; it does not invent a crash that is not in them.

Examples

Key terms

Monte Carlo simulation
Repeating a calculation thousands of times with randomness to see the range of results
Resampling
Drawing trades at random from the list, with replacement
Percentile
Value below which a given percentage of results falls
Path
A particular order of trades and the resulting equity trajectory
Take the mission on Doji Academy

← Back to the index