Historical price data limitation - cant load price data for dates older than 1 year before test starting date
Is that true, or are you guessing? Did you try starting the tester earlier than 2019?
- If the server has history, just reject all ticks earlier than your 2019.
- Otherwise, you have to download history from some other source.
Hello!
Did anyone find any solution to this?
It seems there is one year limit on the loaded data.
Is there any way to change that limit?
Thank you so much!
Yes there is a one year limit as documented.
And yes there are solutions to deal with it, it was discussed on some other topics, please do a search.
Thank you @Alain Verleyen!
I have spent 2 days looking for the solution :( but it's getting hard to find the right one or getting the expected results.
I have tried this ones:
But even with the last solution I'm only getting the limited bars when asking for 200:ChartNavigate solution: https://www.mql5.com/en/forum/229215
CopyTime solution: https://www.mql5.com/en/docs/series/timeseries_access
CopyTime solution 2: https://www.mql5.com/en/forum/286608
2023.05.01 18:17:16.336 Core 01 EURUSD_M1_EST7,Weekly: history cache allocated for 603 bars and contains 53 bars from 2011.01.02 00:00 to 2012.01.01 00:00
2023.05.01 18:17:16.336 Core 01 EURUSD_M1_EST7,Weekly: history begins from 2011.01.02 00:00
Could you just give me some hint? Is one of these solutions the one that can solve this problem?
Is the right solution valid for both backtesting and debug modes?
Thank you so much!
- 2018.03.01
- www.mql5.com
Thank you @Alain Verleyen!
I have spent 2 days looking for the solution :( but it's getting hard to find the right one or getting the expected results.
I have tried this ones:
But even with the last solution I'm only getting the limited bars when asking for 200:ChartNavigate solution: https://www.mql5.com/en/forum/229215
CopyTime solution: https://www.mql5.com/en/docs/series/timeseries_access
CopyTime solution 2: https://www.mql5.com/en/forum/286608
Could you just give me some hint? Is one of these solutions the one that can solve this problem?
Is the right solution valid for both backtesting and debug modes?
Thank you so much!
Please don't mix different topics. This topic is about 1 year history data available in the Tester, from the backtest starting date. These data are downloaded and available automatically.
The links you provided are not about that issue.
What is your actual problem ?
Sorry if I mixed topics, I thougt they were solutions to the problem described here.
My problem is the one you mentioned, I can not access to price data older than one year from the backtest starting date.
For example, on week timeframe, if I execute iClose(_Symbol, _Period, 52) I get the price, but if I try to get the 53 position or greater the price is always 0.0.
And it's the same with other commands like CopyClose, CopyTime and so on.
And I see the other problem is that I'm not being able to find the right topic, as you said I'm mixing them.
Any help to solve this problem would be really appreciated. Thank you!
Sorry if I mixed topics, I thougt they were solutions to the problem described here.
My problem is the one you mentioned, I can not access to price data older than one year from the backtest starting date.
For example, on week timeframe, if I execute iClose(_Symbol, _Period, 52) I get the price, but if I try to get the 53 position or greater the price is always 0.0.
And it's the same with other commands like CopyClose, CopyTime and so on.
And I see the other problem is that I'm not being able to find the right topic, as you said I'm mixing them.
Any help to solve this problem would be really appreciated. Thank you!
Thank you Alain!
We really appreciate the help you give to this community
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Dear all,
Build 2815, MQL5
Hello and I hope this post finds you all well.
It seems that when my EA runs at the strategy tester it cannot access data that are sufficiently old.
In particular, it loads data that are maximum one year old from the date that I wish to start running the EA but not older than that. For instance if I start the EA on 2019.01.01 the oldest date for which I can access price data is 2018.01.02, irrespective of the timeframe used.
2021.02.28 14:17:48.157 USDJPY,M1: history cache allocated for 1180536 bars and contains 370922 bars from 2018.01.02 00:00 to 2018.12.31 21:00
2021.02.28 14:17:48.157 USDJPY,M1: history begins from 2018.01.02 00:00
2021.02.28 14:17:49.057 USDJPY,M30: history cache allocated for 39401 bars and contains 12414 bars from 2018.01.02 00:00 to 2018.12.31 21:00
2021.02.28 14:17:49.058 USDJPY,M30: history begins from 2018.01.02 00:00
2021.02.28 14:17:49.236 USDJPY,H4: history cache allocated for 4927 bars and contains 1554 bars from 2018.01.02 00:00 to 2018.12.31 20:00
2021.02.28 14:17:49.237 USDJPY,H4: history begins from 2018.01.02 00:00
That particular date comes up as the result in both of the following cases:
datetime(SeriesInfoInteger(_useSymbol,PERIOD_M1,SERIES_FIRSTDATE))
datetime(SeriesInfoInteger(_useSymbol,PERIOD_M1, SERIES_TERMINAL_FIRSTDATE))
My question is the following:
Does anybody know how I can force the EA to load price data for dates older than 2018.01.02 00:00 (one year before the date on which I start running the EA)?
Given that 2018.01.02 00:00 is the very first date in the history of the symbol on the server, is it possible for this date to be changed?
I have already tried the following but have not managed to make any of the proposed solution work..
A) ChartNavigate() (after reading https://www.mql5.com/en/forum/229215 )
B) ROMAN KOTOV’s proposed code, comment #8( https://www.mql5.com/en/forum/229215)
C) CheckLoadHistory() (https://www.mql5.com/en/docs/series/timeseries_access)
D) CopyTime () (Alain Verleyen’ proposal at comment #3) (https://www.mql5.com/en/forum/286608 )
Any help would be massively appreciated.
Thank you for your time in advance.