EA-914 · Trend Following

Moving Averages With Frames

This EA trades based on a simple Moving Average crossover signal where price crossing the SMA triggers entries and exits. It includes optimized lot sizing that reduces position size after consecutive losses, and integrates MetaTrader's FrameGenerator for visualizing optimization results during backtesting.

Open the interactive view (equity curve, symbol switch)

Key facts

RiskMedium
Blow-up riskLow
Rating★★☆☆☆
TypeTrading EA
TimeframesM15, H1, H4
IndicatorsSMA
AuthorMetaQuotes Software Corp.

Backtest results (H1, about 1 year)

SymbolP&LAnnualMax DDTradesWin rateSharpeRecoveryLosing streakPer tradeStatus
EURUSD+5.90%+5.11%2.69%12551.20%————Same as other EAs
GBPUSD+4.10%+3.55%3.85%12949.20%————Same as other EAs
USDJPY+1.42%+1.23%6.53%12646.40%————Same as other EAs
XAUUSD+180.74%+134.64%36.71%12656.30%————Same as other EAs

On every market this backtest is identical to EA-1921. The automatic conversion almost certainly lost what makes this EA different (a custom indicator, a filter or the money management), so these results are not ranked or counted.

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

  • Has no stop loss or trailing stop

On its own this is not a typical blow-up pattern, 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 relationship between price and a Simple Moving Average (SMA) to determine trend direction. Entry conditions are: sell when a bar opens above the MA and closes below it, buy when a bar opens below the MA and closes above it — essentially trading on price crossover of the MA line. Exit conditions are: close a long position when price crosses from below to above the MA, close a short position when price crosses from above to below the MA. Position sizing uses a dynamic lot calculation based on account free margin and the maximum risk percentage, with lot size decreased according to the number of consecutive historical losses divided by the DecreaseFactor. Money management controls maximum risk per trade at 2% of account equity via the MaximumRisk parameter, while also respecting the symbol's minimum/maximum volume and volume step constraints. The strategy only trades on the first tick of a new bar and requires more than 100 bars of history as an additional safety check.

Strengths

  • Dynamic position sizing that automatically adjusts lot size based on account balance and risk percentage
  • Automatic lot reduction after consecutive losses helps control drawdown
  • Integrated FrameGenerator for optimization visualization, facilitating parameter analysis
  • Respects symbol volume constraints (min/max/step), preventing invalid orders
  • Trades only on the first tick of a new bar, avoiding duplicate signals

Weaknesses

  • No stop-loss or take-profit set; positions rely entirely on signal-based closing, creating significant loss risk
  • Overly simple strategy logic; a single MA crossover signal prone to frequent false breakouts
  • Does not account for spread and slippage impact on trading costs
  • Position close uses a fixed 3-point slippage which may be insufficient during volatile markets
  • DecreaseFactor reduction logic does not activate when consecutive losses equal 1, creating a logic edge case

Possible improvements

  • Add stop-loss and take-profit parameters to set explicit risk boundaries for each trade
  • Add multiple confirmation conditions (e.g., volume, RSI, or second-period MA filter) to reduce false signals
  • Add spread filter and trading session filter to avoid high-cost trading periods

Risk assessment

Overall risk: Medium

  • No stop-loss; if the MA crossover signal does not appear for an extended period, losses could be substantial
  • Single indicator crossover strategy generates frequent false signals in ranging markets leading to consecutive losses
  • The lot reduction mechanism may be insufficient to control risk during extreme market conditions

Evaluation scores

Code quality3.0
Strategy logic2.0
Risk management3.0
Robustness2.0
Innovation2.0
Documentation2.0
Overall2.3

Parameters

ParameterDefaultDescription
MaximumRisk0.02Maximum risk per trade as percentage of account free margin
DecreaseFactor3Position decrease factor after consecutive losses
MovingPeriod12Moving average calculation period
MovingShift6Moving average shift

Similar Trend Following 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.