Dear colegues,
I want to discuss here about an idea I found on the site http://www.lightpatch.com/forex , especially about Divergence Trader EA http://www.forexmt4.com/_MT4_Experts...e%20Trader.mq4 . I test this robot since January and the results on H1 are amazing! On other TFs everything was huge loss. you can look here: https://www.forexfactory.com/valim1975#acct.55
Mainly, this robot checks the divergence between SMA 88 and SMA 7 (Both with price open). The formula is
( I think it is a mistake, because finally (maF2-maS2) is returned , it means difference between previous values of SMA7 and SMA88 - for the people does not understand MQL)
I made a histogram that reflects the signals for trades given by the EA. I think this is the best way to visualize the situation.
I put also a modified histogram to ignore reversals, because the original may buy on falling and sell on uptrend ...at least for a while, that I don't consider a good thing.
I am testing both versions.
if I find here enthusiasts that would like to test and try other values of SMAs, or to make any changes, I am open to implement...maibe we can make it better...
It is a lot of work, and for this reason what I advice you to modify:
1.
Fast_Period=7;
Fast_Price =1;
Slow_Period=88;
Slow_Price = PRICE_OPEN;
you can try to change values of periods, and also of price applied ( see values below):
PRICE_CLOSE=0
PRICE_OPEN =1
PRICE_HIGH=2
PRICE_LOW =3
PRICE_MEDIAN=4 (Median price, (high + low)/2)
PRICE_TYPICAL=5 (Typical price, (high + low + close)/3)
PRICE_WEIGHTED 6 (Weighted close price, (high + low + close + close)/4)
DVBuySell=0.0011;
DVStayOut=0.0079;
these are values in pips of the interval of trading. these are for 4-5 digits (example EUDUSD, GBPUSD) ; for 3 digits you must cut 00 after the dot (for USDJPY will be 0.11 and 0.79 )
Look forward for your reaction. Hope we can make a good job....
I want to discuss here about an idea I found on the site http://www.lightpatch.com/forex , especially about Divergence Trader EA http://www.forexmt4.com/_MT4_Experts...e%20Trader.mq4 . I test this robot since January and the results on H1 are amazing! On other TFs everything was huge loss. you can look here: https://www.forexfactory.com/valim1975#acct.55
Mainly, this robot checks the divergence between SMA 88 and SMA 7 (Both with price open). The formula is
Inserted Code
DVBuySell=0.0011; DVStayOut=0.0079 ------------- maF1=iMA(Symbol(),0,7,0,MODE_SMA,F_Price,0); maS1=iMA(Symbol(),0,88,0,MODE_SMA,S_Price,0); dv1=(maF1-maS1); maF2=iMA(Symbol(),0,7,0,MODE_SMA,F_Price,1); maS2=iMA(Symbol(),0,88,0,MODE_SMA,S_Price,1); dv2=((maF1-maS1)-(maF2-maS2)); return(dv1-dv2);
( I think it is a mistake, because finally (maF2-maS2) is returned , it means difference between previous values of SMA7 and SMA88 - for the people does not understand MQL)
I made a histogram that reflects the signals for trades given by the EA. I think this is the best way to visualize the situation.
I put also a modified histogram to ignore reversals, because the original may buy on falling and sell on uptrend ...at least for a while, that I don't consider a good thing.
I am testing both versions.
if I find here enthusiasts that would like to test and try other values of SMAs, or to make any changes, I am open to implement...maibe we can make it better...
It is a lot of work, and for this reason what I advice you to modify:
1.
Fast_Period=7;
Fast_Price =1;
Slow_Period=88;
Slow_Price = PRICE_OPEN;
you can try to change values of periods, and also of price applied ( see values below):
PRICE_CLOSE=0
PRICE_OPEN =1
PRICE_HIGH=2
PRICE_LOW =3
PRICE_MEDIAN=4 (Median price, (high + low)/2)
PRICE_TYPICAL=5 (Typical price, (high + low + close)/3)
PRICE_WEIGHTED 6 (Weighted close price, (high + low + close + close)/4)
DVBuySell=0.0011;
DVStayOut=0.0079;
these are values in pips of the interval of trading. these are for 4-5 digits (example EUDUSD, GBPUSD) ; for 3 digits you must cut 00 after the dot (for USDJPY will be 0.11 and 0.79 )
Look forward for your reaction. Hope we can make a good job....
Attached File(s)
histo Divergence modified.ex4
11 KB
|
1,904 downloads
histo Divergence Original.ex4
11 KB
|
1,280 downloads