Need an EA for GBP/USD strategy...

 

I just recently was told about a strategy that has a 90% success rate and I'd like to see if someone could code an EA for it.

Here are the rules...

1) This only works on the GBP/USD & only on the 15 minute charts.

2) Take the High & Low of these 3 candles - 08:15, 08:30, 08:45 (EST-NY time)

3) Buy when the price reaches 1 pip above the High

4) Sell when the price reaches 1 pip below the Low

5) Initial trailing stop of 15

6) When the price reaches 15 pips profit, change trailing stop to 5

If anyone can do this that would be fantastic!

Thanks a million!

 

https://www.mql5.com/en/forum/194293

works on whatever chart you want although 15m is riskyif you could use it on a 1h chart it would be a good one

 
wadeboxjr:
I just recently was told about a strategy that has a 90% success rate and I'd like to see if someone could code an EA for it. Here are the rules... 1) This only works on the GBP/USD & only on the 15 minute charts.2) Take the High & Low of these 3 candles - 08:15, 08:30, 08:45 (EST-NY time)3) Buy when the price reaches 1 pip above the High4) Sell when the price reaches 1 pip below the Low5) Initial trailing stop of 156) When the price reaches 15 pips profit, change trailing stop to 5 If anyone can do this that would be fantastic! Thanks a million!

I can code that, very easy. Just tell me if you still want it coded. At what time would the trade be placed? 9:00?

 

So once price breaks breaks the hi/lo for that time, that's it? I mean, no more trades, and does one only trade during the US session?

 

Hi anamy Could you please code the EA. Would be very much appreciated. many thanks

 

Hi,

I would be interested in a copy of this EA too if it has been done, with a couple of modifications to parameters.

cheers

 

I can see that there is a lot of interest in having this done, so I decided to do it. This is the description for the observationHour value that is in the EA.

// This value is the hour that the EA will look to for the highs and lows.

// This will have to be changed due to differing time zones.

// The times that the EA will be provided with are the time zone of your broker,

// not YOUR time zone where you live.

// Pending orders will be placed on the first or second minute of the hour after

// observation hour.

// It's default setting of 13 is in accordance with the strategy for time

// zone GMT; pending orders will be placed at 14:00 or 14:01.

// Example: If your broker is in EST time zone, the value would be 8.

I've run a couple of backtests and it seems to place all the trades according to sytem correctly. If anyone notices any bugs, please post and tell me about it.

Files:
 
anamy:
I can see that there is a lot of interest in having this done, so I decided to do it. This is the description for the observationHour value that is in the EA. // This value is the hour that the EA will look to for the highs and lows. // This will have to be changed due to differing time zones. // The times that the EA will be provided with are the time zone of your broker, // not YOUR time zone where you live. // Pending orders will be placed on the first or second minute of the hour after // observation hour. // It's default setting of 13 is in accordance with the strategy for time // zone GMT; pending orders will be placed at 14:00 or 14:01. // Example: If your broker is in EST time zone, the value would be 8. I've run a couple of backtests and it seems to place all the trades according to sytem correctly. If anyone notices any bugs, please post and tell me about it.

anamy,

First thank you for building this EA. I have a couple questions.

Will it check the whole hour on a 5 minute chart since that is the chart I am seeing most profitable?

And instead of 1 pip above the High and Low being put in where can I change it to say 5 pips to filter out the whipsaws?

 
Toddr:
Will it check the whole hour on a 5 minute chart since that is the chart I am seeing most profitable?

I can add whatever features you think will make it better, but I'm not quite sure what you're asking there. What the EA does it is will check for the highest high and the lowest low (of the past 3 bars) for the 15 minute chart, regardless of what the timeframe the EA is currently attached to. So if it is on a 5 Minute or a daily chart, it'll still be checking internally using the 15 minute bars, as per the strategy.

 
anamy:
I can add whatever features you think will make it better, but I'm not quite sure what you're asking there. What the EA does it is will check for the highest high and the lowest low (of the past 3 bars) for the 15 minute chart, regardless of what the timeframe the EA is currently attached to. So if it is on a 5 Minute or a daily chart, it'll still be checking internally using the 15 minute bars, as per the strategy.

I want it to check a whole hour on the 5 minute chart instead of the 15 minute. Example 1400,1405,1410,1415 all the way up to 1455.

Would I just change the section like I have below?: (Just a crack at it because I would like to learn more about building EAs)

double highestHigh=0, lowestLow=1000;
int index=1;

// Determine the entry values for the upcoming set of orders
while (index != 4)
{
if (iHigh(NULL, 5, index)>highestHigh)
highestHigh=iHigh(NULL, 5, index);
if (iLow(NULL, 5, index)<lowestLow)
lowestLow=iLow(NULL, 5, index);
index++;
}

 

Yep, you're certainly on the right track. Next you'd have to change

while (index != 4)

to

while (index != 13)

so it'll read the appropriate number of bars. Your setup would then be reading a total of 12 bars (starting on the previous bar which is 1) on the 5 minute charts instead of 3 on the 15 minute chart. I think 13 would be the right number, but don't quote me on that.

Reason: