指定
Hi, I need to make an EA for use on MT5, on a simple strategy based on the High and Low of candles. Below is the strategy where I should be able to change the variables (number of candles, candle frequency, hours, multiplier, etc):
Entry Long
--------------------
Open Position = 0
AND
CMP > Highest High of last 5 candles
--------------------
Exit Long
--------------------
Time > Entry Time + 5 hours
AND
CMP < Lowest Low of last 5 candles
--------------------
OR
--------------------
Time < Entry Time + 5 hours
AND
CMP < Lowest Low of last 5 candles
AND
CMP < Entry Price * 0.99
--------------------
OR
--------------------
Time < Entry Time + 5 hours
AND
CMP < Lowest Low of last 5 candles
AND
CMP > Entry Price
--------------------
Entry Short
--------------------
Open Position = 0
AND
CMP < Lowest Low of last 5 candles
--------------------
Exit Short
--------------------
Time > Entry Time + 5 hours
AND
CMP > Highest High of last 5 candles
--------------------
OR
--------------------
Time < Entry Time + 5 hours
AND
CMP > Highest High of last 5 candles
AND
CMP > Entry Price * 1.01
--------------------
OR
--------------------
Time < Entry Time + 5 hours
AND
CMP > Highest High of last 5 candles
AND
CMP < Entry Price
--------------------
At any point, only one of the two (Long or Short) entries should be active.