Edgoro
Strategy

Backtest in the chat: Monte Carlo, walk-forward and higher costs on every test

Edgoro now backtests a strategy right under it in the chat and runs four robustness checks on every test. What each check does, and three real results.

Since 16 November 2026, Edgoro backtests a strategy right where you build it: under a Pine Script strategy, a crypto bot or an MT5 Expert Advisor, one click tests the latest version on up to three years of real crypto candles, then runs four robustness checks (Monte Carlo, walk-forward with re-tuning, higher costs and the neighbouring timeframes). We ran three classic strategies through it: none passed more than one of the four checks, including one that made +10.4%.

This post explains what changed, how each check decides pass or fail, and what the three tests showed. Backtests are simulations of the past, for education: they don't predict returns.

What changed

  • Backtests in the chat. With the Backtest Lab option, a backtest card appears under any strategy the chat writes. Pick the pair, the timeframe and the period; the saved version is tested with all the checks, and the card shows the verdict, five numbers and the checks.
  • Versions compared. When an earlier version of the same strategy was tested, the card puts both tests side by side: net return, profit factor, drawdown, trades, robustness and verdict.
  • "Improve from these results". One click sends the numbers and the failed checks back to the AI, with an instruction to fix the weaknesses without curve-fitting. The next version is tested again with the same settings, so you can see whether the change helped.
  • Code fixed until it passes. Errors from MetaEditor (MQL5), Python's py_compile and Edgoro Pine Check now go back to the AI automatically until the code passes, up to 5 times in a row, and the loop stops early if a fix brings back the same errors.

The four robustness checks

Every test still gets its verdict (robust, fragile, over-fitted or not enough trades) from the out-of-sample check on the last 25% of the period. The four checks run after it, on the same rules, and none of them changes the strategy.

CheckWhat it doesPasses when
Monte CarloRedraws the trades 1,000 times, with replacement, to see the outcomes the same edge could have produced in another orderAt most 20% of the paths end with a loss, and the worst 5% of drawdowns stay at 40% or less (needs 30 trades or more)
Walk-forwardCuts the period into 5 parts; before each of parts 2 to 5, re-tunes up to two main settings (5 values each, around the current ones) on everything before it, then trades the best one on the part, unseenAt least 60% of the unseen parts are profitable and their total is positive
Higher costsThe same test with fees ×2, slippage ×3, and bothStill profitable with both
Other timeframesThe same rules on the timeframe just below and just aboveAt least one of them is profitable, with 10 trades or more

The card sums it up as solid (every check that could run passed), mixed (at least half) or weak. A check that can't run, for example a Monte Carlo on 21 trades, is shown as such and isn't counted.

Three real tests

We ran three textbook strategies on Binance spot candles from 16 November 2023 to 16 November 2026, with the default costs (0.1% fees per side, 0.02% slippage), risking 1% per trade with an ATR stop.

StrategyMarketTradesNet returnBuy & holdVerdictChecks passed
EMA 20/50 cross, longs above the 200 EMA, 2R targetETH/USDT 4h34-6.4%-10.8%Fragile1 of 4 (walk-forward)
RSI(14) back above 30, above the 200 EMA, 2R targetBTC/USDT 1h39-6.2%+72.6%Fragile0 of 4
Donchian 20 breakout, long and short, ATR trailing stopSOL/USDT 4h217+10.4%+11.2%Over-fitted1 of 4 (timeframes)

The breakout that made money

The Donchian breakout is the instructive one: +10.4% over three years with a profit factor of 1.09, a result many backtesters would show off. The checks tell a different story:

  • Out-of-sample: -4.9% on the last 25% of the period (56 trades), hence the over-fitted verdict.
  • Monte Carlo: 37% of the 1,000 redrawn paths end with a loss, and 1 in 20 draws down 33.5% or more.
  • Higher costs: with fees ×2 and slippage ×3, profit factor 0.97 and -3.1%. The edge was about the size of the costs.
  • Walk-forward: re-tuning the channel lengths before each part made money on 2 of the 4 unseen parts (+12.1% in total), short of the 3 needed.
  • Other timeframes: the only pass. On daily candles, profit factor 1.18 and +2.6% (38 trades); on 1-hour candles, -51.8% over 891 trades.

The cross that re-tuned well

The ETH EMA cross lost money as tested (profit factor 0.74), but the walk-forward passed: re-tuned on the past only, it made money on 3 of 4 unseen parts (+7.3%), and the unseen parts kept 55% of the tuned yearly rate. The other checks failed (83% of Monte Carlo paths end with a loss; profit factor 0.59 with higher costs), so the verdict stays fragile. A single passing check is a lead to test, not a result.

The dip-buy that missed the trend

The BTC RSI strategy took 39 trades in three years and finished at -6.2%, while buying and holding BTC returned +72.6% over the same period. No check passed: in a strong uptrend, this dip-buying rule lost money on balance.

What it can't do yet

  • Markets. Rule-based tests run on 20 USDT spot pairs. Since 17 November 2026, an MT5 Expert Advisor runs in the real MetaTrader 5 Strategy Tester instead, on EUR/USD, GBP/USD, USD/JPY, USD/CHF, USD/CAD, AUD/USD, NZD/USD, gold and silver (the broker's own history, spreads and swaps), with the verdict and the same four checks: the tester re-runs the EA with re-tuned inputs for the walk-forward and on the neighbouring timeframes, and the higher-costs check adds a $7 commission per lot and a wider spread. Stocks and indices can't be tested.
  • The rules language. Indicators are limited to EMA, SMA, RSI, ATR, MACD, Bollinger Bands, Stochastic, VWAP and highest/lowest. Anything else is refused with an explanation, not approximated.
  • Each test counts toward the 100 tests a month of the option.

The Backtest Lab docs list every rule and threshold. To try it, build a strategy, then click Backtest it under the answer.

Backtested and simulated results are hypothetical and do not guarantee future performance. Trading involves substantial risk of loss. This article is for education, not investment advice.

Frequently asked questions

Can I backtest a strategy without leaving the chat?

Yes, with the Backtest Lab option. Under a Pine Script strategy, a crypto bot or an MT5 Expert Advisor, the backtest card tests the latest version on up to three years of crypto candles and runs the four robustness checks.

What does the Monte Carlo check do?

It redraws the strategy's trades 1,000 times with replacement and looks at the spread of outcomes. It passes when at most 20% of the paths end with a loss and the worst 5% of drawdowns stay at 40% or less. It needs at least 30 trades.

How does the walk-forward check work?

The period is cut into 5 parts. Before each of parts 2 to 5, up to two of the strategy's main settings are re-tuned on everything before it, and the best setting is traded on the part, unseen. It passes when at least 60% of those parts are profitable and their total is positive.

Can I backtest forex or MT5 strategies?

Yes for MT5 Expert Advisors: the chat runs them in the real MetaTrader 5 Strategy Tester on EUR/USD, GBP/USD, USD/JPY, USD/CHF, USD/CAD, AUD/USD, NZD/USD, gold and silver, with the broker's own history. Pine strategies and crypto bots are tested on crypto pairs.

Want our studies and guides first when you search? Add Edgoro as a preferred source on Google.

Build it with Edgoro

Describe your strategy in plain English and get a TradingView indicator in Pine Script v6 or a MetaTrader 5 Expert Advisor in minutes. Every first purchase is covered by a 7-day money-back guarantee.

Build your indicator with Edgoro