Exp_2MoHLC
This EA trades based on the 2MoHLC custom indicator, which generates a cloud from two moving averages. It supports two modes: cloud color change (trend reversal) and cloud breakthrough (price breaking through the cloud boundary), opening buy/sell positions accordingly with configurable stop loss and take profit.
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 | 0.00% | 0.00% | 0.00% | 0 | — | — | — | — | — | Custom indicator approximated |
| GBPUSD | 0.00% | 0.00% | 0.00% | 0 | — | — | — | — | — | Custom indicator approximated |
| USDJPY | 0.00% | 0.00% | 0.00% | 0 | — | — | — | — | — | Custom indicator approximated |
| XAUUSD | 0.00% | 0.00% | 0.00% | 0 | — | — | — | — | — | Custom indicator approximated |
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.
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 concept is based on the 2MoHLC indicator which generates upper and lower cloud bands (UpValue and DnValue) from two moving averages with different periods. In CloudColor mode, an uptrend is identified when the upper band is above the lower band, and a buy signal is generated when the bands cross from the previous bar; conversely for sell signals. In Breakdown mode, a buy signal occurs when the close price breaks above the maximum of both cloud bands, and a sell signal when it breaks below the minimum. Exit conditions include fixed stop loss and take profit in points, as well as position closing on trend reversal signals. Position sizing is controlled by the MM parameter, where negative values represent fixed lot size and positive values represent a share of the deposit. Money management relies on the external TradeAlgorithms.mqh library functions (BuyPositionOpen/SellPositionOpen) with slippage protection and signal timestamp mechanisms. The strategy uses the IsNewBar mechanism to ensure signals are only calculated on new bar formation, preventing repeated trades on every tick.
Strengths
- Dual-mode design (cloud color change and cloud breakthrough) provides flexible trading strategy options
- Complete open/close permission controls allow fine-tuning of long and short directions
- Uses IsNewBar mechanism to avoid recalculating signals on every tick, reducing resource consumption
- Complete stop loss and take profit parameters provide basic risk control safeguards
- Handles data copy failures via the Recount flag with basic fault tolerance
Weaknesses
- Depends on external TradeAlgorithms.mqh library with invisible core trading logic, making full risk assessment difficult
- Stop loss of 1000 points and take profit of 2000 points are large, potentially leading to significant single-trade losses
- No trading session filter, may produce unfavorable fills during low liquidity periods
- Lacks trailing stop or break-even mechanism, unable to lock in floating profits
- Does not check for existing positions in the same direction, potentially opening duplicate positions
Possible improvements
- Add trailing stop functionality to lock in profits when price moves favorably
- Add trading session filter and spread filter to avoid opening positions under unfavorable market conditions
- Add same-direction position check to prevent duplicate openings causing overexposure
Risk assessment
Overall risk: Medium
- Position management logic in external library is unauditable, posing unknown risks
- Large stop loss value (1000 points) may result in significant single-trade losses
- No same-direction position check may lead to overexposure
Evaluation scores
Parameters
| Parameter | Default | Description |
|---|---|---|
MM | -0.1 | Deposit ratio; negative value=fixed lot size |
StopLoss_ | 1000 | Stop loss in points |
TakeProfit_ | 2000 | Take profit in points |
Deviation_ | 10 | Maximum slippage in points |
BuyPosOpen | true | Allow buy position opening |
SellPosOpen | true | Allow sell position opening |
BuyPosClose | true | Allow closing long positions |
SellPosClose | true | Allow closing short positions |
InpInd_Timeframe | PERIOD_H4 | Indicator timeframe |
Mode | Breakdown | Indicator mode: cloud color change or cloud breakout |
Period1 | 24 | Moving average period 1 |
Period2 | 48 | Moving average period 2 |
SignalBar | 1 | Bar index for entry signal |
Similar Trend Following EAs
Backtests are historical simulations and do not guarantee future results. Not financial advice.