Expert Advisors • Indicators • Scripts • Libraries

MQL.RobotFX.org is the biggest collection of MetaTrader expert advisors (MT5 & MT4), indicators, scripts and libraries that can be used to improve trading results, minimize risks or simply automate trading tasks

MetaTrader 5 Expert Advisor | Russian20-hp1

Idea by: Scriptor

MQL5 code author: barabashkakvn

The Expert Advisor is based on the trend indicator iMA (Moving Average, MA) and the iMomentum oscillator (Momentum). It can work on every tick (Work on every tick = "true") and only at the new bar emergence time (work on every tick = "false").

The work timeframe parameter means the timeframe, on which indicators are created and the bar close prices of which are used.

For Buy and Sell positions, you can separately set Stop Loss (Stop Loss BuyStop Loss Sell) and Take Profit (Take Profit Buy, Take Profit Sell). If you want to disable any of these options, set the appropriate parameter to "0.0".

Trading Signals

If there are no open positions, then position opening signals can be checked:

  • BUY opening signal: (Close of bar #0 > Moving Average on bar #0) AND (Momentum on bar #0 >100.0) AND (Close of bar #0 > Close of bar #1)
  • SELL opening signal: (Close of bar #0 < Moving Average on bar #0) AND (Momentum on bar #0 <100.0) AND (Close of bar #0 < Close of bar #1)

When there are open positions, the possibility of closing is checked:

  • A signal to close BUY: (Momentum on bar #0 <100.0)
  • A Signal to close SELL: (Momentum on bar #0 >100.0))

The results of optimization of work on every tick and work timeframe for EURUSD are provided as default EA parameters. Results of EURUSD testing with default parameters:

MetaTrader Experts, Indicators, Scripts and Libraries

21852