EA-19971 · Breakout

Channels(barabashkakvn's edition)

This EA trades channel breakouts using a fast EMA(2) crossing Envelopes bands based on a slow EMA(220) on the H1 timeframe. It opens BUY when the fast EMA(Close) crosses above an Envelope lower or upper band, and SELL when the fast EMA(Open) crosses below an Envelope upper or lower band. Positions are managed with configurable trailing stops and optional time-based session filtering.

Open the interactive view (equity curve, symbol switch)

Key facts

CategoryBreakout
RiskMedium
Blow-up riskHigh
Rating★★★☆☆
TypeTrading EA
TimeframesH1
IndicatorsEMA, Envelopes
AuthorMetaQuotes Software Corp.

Backtest results (H1, about 1 year)

SymbolP&LAnnualMax DDTradesWin rateSharpeRecoveryLosing streakPer tradeStatus
EURUSD-4.24%-3.70%8.90%10.00%————Too few trades
GBPUSD+2.50%+2.17%6.57%10.00%————Too few trades
USDJPY+2.15%+1.87%6.62%10.00%————Too few trades
XAUUSD-93.96%-90.16%94.47%10.00%-1.89-0.991−$9,395.83Account stopped out

Converted from MQL5 to Python and run with the same rules for every EA. Positions use MT5 lot sizes (100,000 units per FX lot, 100 oz per gold lot) with 1:100 leverage, one order at a time, and a stop-out below 10% of the starting balance. Sharpe is computed from the equity curve. Results marked as unreliable are shown for completeness only.

Against the other Breakout EAs with a reliable result on the same market: XAUUSD: better than 5% of 19

Month by month

MarketMonths with a gainBest monthWorst month
XAUUSD0%0.00% 2026-02-91.85% 2026-01

From the backtest equity curve, sampled about every two days; only reliable results.

Blow-up risk: High

  • Hit a stop-out in our backtest (equity below 10%) on XAUUSD

High: stopped out in our backtest, or martingale/grid sizing without a stop loss. Elevated: martingale or grid sizing with a stop loss, or several positions at once without a stop loss. What the label means and what we found →

Strategy analysis

The strategy concept is based on Envelopes channel breakouts, using three Envelopes indicators with different deviations (0.3%, 0.7%, 1.0%) to construct multi-layer channels, combined with EMA(2) as the fast signal line and EMA(220) as the midline baseline. Entry conditions for BUY signals include EMA(2,Close) crossing above any Envelopes lower band, any upper band, or the EMA(220) itself; SELL signals are triggered when EMA(2,Open) crosses below any Envelopes upper band, any lower band, or the EMA(220), all using crossover confirmation. Exit conditions rely solely on trailing stop mechanisms — when floating profit exceeds the trailing stop distance plus step, the stop loss is adjusted to current price minus trailing stop (for buys) or plus trailing stop (for sells), with no mandatory fixed take-profit or stop-loss exits (input defaults are 0). Position sizing uses a fixed lot size (InpLots) with no pyramiding or position reduction logic, and only one position direction is held at a time (new entries only when total==0). Money management lacks dynamic lot calculation or risk-percentage controls, only performing compliance checks for minimum/maximum lots and lot step granularity.

Strengths

  • Multi-layer Envelopes channel design (0.3%/0.7%/1.0%) provides breakout signals at multiple levels, increasing entry flexibility
  • BUY uses Close price EMA while SELL uses Open price EMA, differentiating price bases for long/short signals with reasonable logic
  • Trailing stop mechanism locks in floating profits and protects gains
  • Session time filter helps avoid trading during inactive hours
  • Lot validation (LotsMin/LotsMax/LotsStep) prevents invalid order placement

Weaknesses

  • Stop loss and take profit default to 0, leaving positions completely unprotected if trailing stops don't trigger — extremely risky
  • Only allows new entries when total positions==0, but lacks new bar detection, so the same bar may repeatedly trigger signals causing logic confusion
  • BUY conditions include a non-crossover logic (MA<lower band AND previous also<lower band), inconsistent with other crossover conditions, potentially generating persistent signals
  • Very short EMA(2) as signal line is extremely sensitive to price noise, prone to frequent false breakout signals
  • No spread filter — large spreads may already consume the breakout signal margin
  • InpTrailingStep is missing the 'input' keyword, so users cannot adjust it from the parameter panel

Possible improvements

  • Add new bar detection (IsNewBar) to prevent repeated signal calculation and duplicate entries within the same bar
  • Set reasonable non-zero default stop loss/take profit values and add spread filter to pause trading when spreads are excessive
  • Correct the non-crossover BUY condition to a crossover condition for strategy consistency, or label it as a separate signal type
  • Add 'input' keyword to InpTrailingStep for configurability, and add maximum position count control parameter
  • Add indicator data validity checks (skip current tick when iMAGet/iEnvelopesGet returns 0) to avoid decisions based on invalid data

Risk assessment

Overall risk: Medium

  • Default SL/TP of 0 means unlimited loss risk if trailing stop doesn't trigger in time
  • No new bar detection allows repeated signal triggers on the same bar, partially mitigated by total==0 check
  • EMA(2) signal line has high noise sensitivity, potentially generating false breakouts and frequent losing trades
  • Indicator read failures return 0.0 instead of aborting, potentially triggering trades with invalid data

Evaluation scores

Code quality3.0
Strategy logic3.0
Risk management2.0
Robustness2.0
Innovation3.0
Documentation1.0
Overall2.3

Parameters

ParameterDefaultDescription
InpLots0.1Trading lot size
InpStopLossBuy0longstop losspoints (0=no)
InpStopLossSell0shortstop losspoints (0=no)
InpTakeProfitBuy0longtake profitpoints (0=no)
InpTakeProfitSell0shorttake profitpoints (0=no)
InpTrailingStopBuy30longtrailing stop in points
InpTrailingStopSell30shorttrailing stop in points
InpTrailingStep1Trailing stop step in points
InpUseHoursfalseEnable trading session filter
InpFromhour_00Trading start hour
InpTohour_23Trading end hour
m_magic43915489Magic number to identify strategy positions

Similar Breakout EAs

Backtests are historical simulations and do not guarantee future results. Not financial advice.

Get the weekly Arena report

One email a week: ranking changes, new signals and new research. No spam; unsubscribe any time.