different results from ADX in MT4 and MT5

 

I was always wondering why direct EA conversions from MT5 to MT4 generated sometimes totally different results. Today i noticed that MT4 and MT5 adx indicators return different values with exact same settings. Why is that? How do i bypass that so that both of them generate same results?

MT4 

MT5 

 

i have found topic :
https://www.mql5.com/en/forum/145838 

that really sucks. Does it mean I have to code my own iADXmt4 function like i did with iADXWilder ? MT4 was redesinged to make it easy to convert MT4 strategies easily, too bad noone thought of iADX.

 
angreeee:

I was always wondering why direct EA conversions from MT5 to MT4 generated sometimes totally different results. Today i noticed that MT4 and MT5 adx indicators return different values with exact same settings. Why is that? How do i bypass that so that both of them generate same results?

 

 

Do you use MT4 and MT5 at the same broker and with the same data?

It seems to be completly different data as you can see if you check and compare the OHLC Values of the specified candle.

Maybe it's caused by the GMT and DST settings. 

 
blueball:

Do you use MT4 and MT5 at the same broker and with the same data?

It seems to be completly different data as you can see if you check and compare the OHLC Values of the specified candle.

Maybe it's caused by the GMT and DST settings. 

Yes - it is Roboforex, same account types, just MT4 and MT5. You are right, they are different. I will compare them to metaquotes chart.

Do I have any control over settings relating GMT? I see nothing in MT4/MT5 options

EDIT: I cant check it in MQ as there is no such pair as USD/SGD...

 
in 2014 they are the same. It seems the old history is messed up in one of the platforms.
 
angreeee:
in 2014 they are the same. It seems the old history is messed up in one of the platforms.

I think the problem is that the history is provided by different sources.

With MT4 you get the history from the brokers history data base and you get it with a poor qualitiy of 25% on M1.

But with MT5 you always get 100% data qualitiy even with different brokers and i think that the data is provided by Metaquotes.

 

There are some built in functions like TimeGMT and DSTOffset but they are only working in a normal real or demo trading environment.

In the strategy tester TimeGMT is equal to the server time and that's a big problem for Experts that uses time or trading session limitations. 

 

good that i dont have to build any adx functions again. I will just copy settings from my MT5 strategy to MT4 without any changes. 

Thank you for your replies.

I really don't like backtesting in MT4. It is almost useless without 99% tick quality software. (and that software is also problematic - when MT4 terminal needs to be updated)

Reason: