Wrong Prices in testing

 

Hello,

i have got trouble with the prices.


The Bid and ASK Price is wrong! But there is more wrong.

As you see, the chart-date is "24.1", but the code is at "27.1". I don´t know why.

The Price in my EA is 9338/9392, but in Tickdata its 9387. ( I run the EA with real tick data )

I checked the price for the "24.1", its something else too...


Its one year ago, that i coded on this ea last time, there it works.


Have you got an Idea?

Thanks



 
John__Doe:

Hello,

i have got trouble with the prices.


The Bid and ASK Price is wrong! But there is more wrong.

As you see, the chart-date is "24.1", but the code is at "27.1". I don´t know why.

The Price in my EA is 9338/9392, but in Tickdata its 9387. ( I run the EA with real tick data )

I checked the price for the "24.1", its something else too...


Its one year ago, that i coded on this ea last time, there it works.


Have you got an Idea?

Thanks



"24 Jan 21:29" is the datetime of the last "grid" marker, not the current time.

Always use SymbolInfoTick() to get last tick info.

The current time is '16:10:01' but you looked ticks at '16:00:01'.

 

Thank you, but this was a fail from me :)


Its the wrong Price too. The ASK/BID difference in the EA can´t be from real tickdate.


SymbolInfoTick() / SymbolInfoDouble(Symbol(),SYMBOL_BID) / SymbolInfoDouble(_Symbol, SYMBOL_BID) --> All have the same (wrong) result here.



 
John__Doe #:

Thank you, but this was another fail :)


Its the wrong Price too



What ticks did you select ?

What are your Strategy Tester settings ? What MT5 build ? What broker and symbol ?

EDIT: Real or demo ?

What is the tick time (including milliseconds) return for your Latest_Price MqlTick ?

 

Build 3210, Broker - Activetrades, but offline

The Symbol is the Ger30 from Dukascopy


This EA with this Ticks (but another build) was ever working.



What ticks did you select ? ---> I don´t know where i have this option in MT.



Now, i found out, that this bug is for 2 weeks testing. After and before that it seems okay. But i can´s say wheter it comes back, because this EA needs 5 minutes for a testing day.

 
John__Doe #: Build 3210, Broker - Activetrades, but offline. The Symbol is the Ger30 from Dukascopy

Dukascopy? Do you mean you are testing against a Custom Symbol, generated from Dukascopy Tick Data History and not from Activetrades live data?

EDIT: Now that I look at your screenshot again, you are in fact using a Custom Symbol — "Custom\Cash Indices\Ger303".

 
Fernando Carreiro #:

Dukascopy? Do you mean you are testing against a Custom Symbol, generated from Dukascopy Tick Data History and not from Activetrades live data?

EDIT: Now that I look at your screenshot again, you are in fact using a Custom Symbol — "Custom\Cash Indices\Ger303".

yes, its custom, but these tiks worked in past (with this EA). The only thing changed is the MT-build ( ...and probably some configuration of MT5)

 
John__Doe #: yes, its custom, but these tiks worked in past (with this EA). The only thing changed is the MT-build ( ...and probably some configuration of MT5)

I'm not sure, but I vaguely remember reading something about a problem with Custom Symbols on the newer builds, but I can't remember which build nor what the exact problem was.

EDIT: Ok, I was wrong. I found the thread and it was nothing related. Ignore my previous sentence.

 
John__Doe #:yes, its custom, but these tiks worked in past (with this EA). The only thing changed is the MT-build ( ...and probably some configuration of MT5)

Have you tried re-generating the Custom Symbol again with the newer build?

 
Fernando Carreiro #:

Have you tried re-generating the Custom Symbol again with the newer build?

yes.

The BID/ASK Price is alltime the same for 2 weeks, then its okay.



But.... can this have something to do with the Flags of the Ticks?

Here is another day, with something wrong at ASK price, but it seems nearly okay

Flags are mostly "10". The ASK price in the EA is (probably) from The Flag 4.


Here a screenshot from maximum wrong Price:

And the Flags are in the wrong weeks all between 20-30 as i see.


 
Could be a lot of things, Custom symbol issue, Strategy Tester issue, debugger, etc...without the data and source code to reproduce the issue it's hard to say something useful.
Reason: