Skip to content
All library documents

Momentum EA Using Close Comparisons with Reversing Entry Signals

Article MQL5 code base

Summary

This description presents a MetaTrader expert advisor that generates trading signals by comparing the close price of the current bar with the close on a configurable comparison bar. Signals are checked when a new bar appears, while trailing-stop management runs continuously. When a position opens, the EA places stop-loss and take-profit levels immediately; setting those values to zero disables the corresponding feature.

The signal rules are symmetric: a buy opening signal also closes a short position, and a sell opening signal also closes a long position. The existing position is closed before the opposing position is opened. The description says the EA supports both netting and hedging accounts, but it does not specify the comparison-bar parameters, exact signal thresholds, asset class, or position sizing. It provides no backtest results or risk-adjusted performance evidence, so the text explains operating behavior rather than demonstrating profitability.

Key ideas

  • The EA compares close prices across bars to determine its directional signals.
  • Signals are evaluated at the start of a new bar, while trailing stops are managed continuously.
  • An opposite opening signal closes the current position before opening the new one.
  • Stop loss, take profit, and trailing behavior can each be disabled through zero-valued settings.
  • The description supplies no performance results or sufficient detail to assess the strategy’s profitability.

Tags

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.