The author of the idea: MaxBau.
The MQL5 code author: Vladimir Karputov.
The Expert Advisor compares the values of five Moving Averages (with period 10, 20, 50, 100 and 200). When the lines of all five indicators get arranged one above the other:
- MA(10) > MA(20) > MA(50) > MA(100) > MA(200) – we have a signal to open a BUY position,
if the indicators are one under the other:
- MA(10) < MA(20) < MA(50) < MA(100) < MA(200) – we have a signal to open a SELL position.
The value of the ADX indicator is additionally checked: if ADX is below 20, BUY and SELL opening signals are ignored.
The EA has been tested in the “Every Tick” mode on two timeframes: H1 and D1. The following settings were used on H1: Stop Loss = 30, TakeProfit = 90. Settings on D1: Stop Loss = 50, TakeProfit = 150.
EURJPY,H1 StopLoss 30 TakeProfit 90:
USDJPY,H1 StopLoss 30 TakeProfit 90:
EURGPB,D1 StopLoss 50 TakeProfit 150:
EURUSD,D1 StopLoss 50 TakeProfit 150: