Exp_DEMA_Range_Channel_Tm_Plus
This EA trades breakout entries based on the Double EMA (DEMA) Range Channel indicator, opening positions when price breaks above or below the channel boundaries. It includes a time-based trade management filter (Tm) that restricts trading to specific hours, plus additional risk controls such as trailing stops and breakeven functionality.
Open the interactive view (equity curve, symbol switch)Key facts
Backtest results (H1, about 1 year)
| Symbol | P&L | Annual | Max DD | Trades | Win rate | Sharpe | Recovery | Losing streak | Per trade | Status |
|---|---|---|---|---|---|---|---|---|---|---|
| EURUSD | +4.89% | +4.24% | 3.21% | 67 | 49.30% | 1.19 | 1.52 | 6 | +$7.30 | Reliable |
| GBPUSD | -1.51% | -1.32% | 8.00% | 75 | 41.30% | -0.26 | -0.19 | 5 | −$2.02 | Reliable |
| USDJPY | +4.58% | +3.97% | 2.24% | 67 | 61.20% | 1.27 | 2.04 | 6 | +$6.83 | Reliable |
| XAUUSD | +6.80% | +5.59% | 73.98% | 77 | 55.30% | 0.48 | 0.09 | 7 | +$12.21 | Reliable |
Profitable on 3 of 4 markets with reliable results.
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: EURUSD: better than 94% of 18 · GBPUSD: better than 44% of 18 · USDJPY: better than 94% of 17 · XAUUSD: better than 53% of 19
Month by month
| Market | Months with a gain | Best month | Worst month |
|---|---|---|---|
| EURUSD | 62% | +3.42% 2026-03 | -1.41% 2026-01 |
| GBPUSD | 38% | +2.39% 2026-03 | -2.00% 2026-06 |
| USDJPY | 69% | +1.87% 2026-09 | -1.44% 2026-08 |
| XAUUSD | 62% | +83.71% 2026-04 | -45.41% 2026-03 |
From the backtest equity curve, sampled about every two days; only reliable results.
Blow-up risk: No blow-up pattern found
None of the usual blow-up patterns were found in the code, and the account was not stopped out in our backtests. That is not a guarantee: any EA can lose money.
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 core is a breakout trading system based on the DEMA Range Channel. DEMA responds faster than standard EMA, and the channel boundaries form dynamic support and resistance zones. Entry conditions: go long when price breaks above the upper channel, go short when price breaks below the lower channel, representing a classic range breakout approach. Exit conditions include fixed take-profit and stop-loss, trailing stop tracking, and breakeven functionality, along with time-based forced closing (Tm feature) that can restrict trading hours or close positions at specified times. Position sizing supports both fixed lots and dynamic calculation based on account equity percentage. Money management provides maximum position limits and daily loss caps as protective mechanisms, though as a breakout strategy it may suffer frequent false breakouts in ranging markets leading to consecutive stop-losses.
Strengths
- DEMA indicator responds faster than standard EMA, capturing trend changes more promptly
- Built-in time filter effectively avoids false breakouts during low-liquidity sessions
- Multi-layer exit mechanism (TP/SL + trailing stop + breakeven) provides comprehensive risk control
Weaknesses
- Breakout strategy prone to frequent false signals in ranging markets leading to consecutive losses
- No built-in spread filter, entry costs may be excessive during high-spread periods
- Fixed channel parameters lack adaptive mechanism for changing market volatility
Possible improvements
- Add volatility adaptation using ATR to dynamically adjust channel width and stop-loss distance
- Add spread filter and ranging market identification module to reduce trading frequency under unfavorable conditions
Risk assessment
Overall risk: Medium
- Breakout strategy lacks effective filtering in ranging markets, may trigger consecutive stop-losses
- Time filter exists but may be disabled by default, increasing risk during low-liquidity sessions
Evaluation scores
Parameters
| Parameter | Default | Description |
|---|---|---|
DEMA_Period | 14 | DEMA period parameter controlling channel sensitivity |
Channel_Deviation | 2.0 | Channel deviation coefficient determining channel width |
StopLoss | 500 | Fixed stop loss in points |
TakeProfit | 1000 | Take profit in points, typically set at gap close |
TrailingStop | 300 | Trailing stop in points |
BreakevenLevel | 200 | Break-even trigger in points |
LotSize | 0.1 | Fixed lot size (used when MMRec disabled) |
TimeFilter_On | true | Enable time filter |
StartHour | 8 | Trading start hour |
EndHour | 20 | Trading end hour |
CloseOnTime | false | Force close positions at specified time |
MagicNumber | 21558 | EA magic number for order identification |
Similar Breakout EAs
Backtests are historical simulations and do not guarantee future results. Not financial advice.