← Retour au blog

Monte Carlo Simulation: How to Test a Trading Strategy's Robustness

📅 2026-03-13
✍️ Strategy Arena
monte carlo backtest robustness bootstrap trading simulation risk management crypto

The Problem with a Standard Backtest

You run a backtest. Your strategy shows +25% over one year. Great, right? Not so fast.

A standard backtest gives you one single scenario: the one that actually happened. But the market could have behaved differently. The trades could have occurred in a different order. Is that +25% the result of a solid strategy, or just luck from a favorable trade sequence?

That's exactly what Monte Carlo simulation answers.

What Is a Monte Carlo Simulation?

The concept is simple: instead of testing your strategy once, you test it thousands of times by reshuffling the trade order for each simulation.

The idea comes from Stanislaw Ulam, a Manhattan Project mathematician, who realized that to estimate complex probabilities, you could simply simulate the process many times and observe the distribution of outcomes.

In trading, this translates to:

  1. Take the actual trades from the backtest (e.g., 50 trades)
  2. Randomly reshuffle them (bootstrap resampling)
  3. Replay the strategy with this different order
  4. Repeat 1,000 times
  5. Analyze the distribution of results

If your strategy is solid, it should be profitable in most scenarios, not just the one that actually occurred.

The Algorithm Used on Strategy Arena

Our implementation uses bootstrap resampling, a robust statistical method. Here's how it works in detail.

Step 1: Trade Extraction

We extract the dollar PnL of each trade from the original backtest. Not the percentage — the actual dollar amount. This is crucial for strategies like DCA or fractional position sizing that invest variable amounts.

Trade 1: +$150
Trade 2: -$80
Trade 3: +$220
Trade 4: -$30
...
Trade 50: +$95

Step 2: Bootstrap (Sampling with Replacement)

For each simulation, we randomly draw 50 trades from the original 50, with replacement. This means the same trade can be drawn multiple times, and some trades may not be drawn at all.

This is the key to bootstrap: we create thousands of plausible trade sequences from the actual data.

Step 3: Building the Equity Curve

For each trade sequence, we build an equity curve starting from the initial capital ($10,000) and adding each trade's PnL:

Capital = $10,000
Trade 1: +$150 -> Capital = $10,150
Trade 2: +$220 -> Capital = $10,370
Trade 3: -$80  -> Capital = $10,290
...

We use an additive model (adding dollar PnL) rather than multiplicative (multiplying by return). Why? Because the additive model is more realistic for strategies that invest a fixed amount per trade, like DCA which invests the same sum every week.

Step 4: Per-Simulation Metrics

For each of the 1,000 simulations, we calculate:

  • The final capital
  • The max drawdown (the largest drop from a peak to a trough)

Step 5: Distribution Analysis

We get 1,000 final capitals and 1,000 max drawdowns. We then calculate:

  • Probability of profit: % of simulations ending above initial capital
  • Probability of ruin: % of simulations losing more than 50% of capital
  • Percentiles: P5 (worst 5%), P25, P50 (median), P75, P95 (best 5%)
  • Robustness score: a 0-100 score combining probability of profit, consistency, and survival

The Robustness Score

This is the most important metric. It combines three factors:

Factor Weight What it measures
Probability of profit 40% Does the strategy win more often than it loses?
Consistency 30% Are results clustered or spread out?
Survival 30% Does the strategy avoid total ruin?

Interpretation:

  • 80-100: Very robust strategy, profitable in nearly all scenarios
  • 60-80: Solid strategy with good probability of profit
  • 40-60: Average strategy, uncertain results
  • 20-40: Fragile strategy, performance depends heavily on luck
  • 0-20: Dangerous strategy, high probability of loss

How to Use It on Strategy Arena

  1. Go to the Backtest page
  2. Select a strategy and an asset (BTC, ETH, SOL, etc.)
  3. Run the backtest
  4. Click Monte Carlo in the results

You'll see:

  • A histogram of final capitals (the probability "bell curve")
  • Sample equity curves (5 possible trajectories)
  • Percentiles (in 95% of cases, you'll end between P5 and P95)
  • The overall robustness score

Common Pitfalls

Don't Confuse Monte Carlo with Backtesting

Monte Carlo does not test your strategy on new data. It tests what would happen if the same trades occurred in a different order. It's a robustness test, not a future performance predictor.

The Survivorship Bias

If your strategy has very few trades (fewer than 10), Monte Carlo isn't reliable. You need a sufficient sample for the bootstrap to be representative.

Overfitting Remains Invisible

An over-optimized strategy (one that perfectly fits historical data) can have an excellent Monte Carlo score while performing poorly in live trading. Monte Carlo tests the robustness of the trade sequence, not the validity of the strategy itself.

Conclusion

Monte Carlo simulation is a powerful tool to go beyond a simple backtest. It transforms a binary question ("did my strategy work?") into a probabilistic one ("what's the probability my strategy will work?").

On Strategy Arena, every backtest can be followed by a Monte Carlo analysis in one click. It's one of the few free tools offering this analysis usually reserved for hedge funds and professional quants.


Test Monte Carlo on your favorite strategies: Run a backtest

Cet article vous a plu ? Partagez-le

𝕏 Partager sur X ✈️ Telegram
Découvrez aussi : ScoreCredit (Crédit)|ScoreInvest (Investissement)|ScoreProtect (Assurance)|ScoreImmobilier (Immobilier)|ScoreZenith (Patrimoine)|StrategyArena (Trading IA)
Rejoindre le canal