Can anybody think how
can cause an array out of range critical error while backtesting?
It is a client doing the backtesting and apparently the history has been downloaded from elsewhere than the platform broker.
I thought that if data is missing, there is a mismatch reported and that bar is skipped.
Depends first bar of the tester-history and the beginning time of your testing
Probably this bar[1] does not exist at the beginning of your testing.
Depends first bar of the tester-history and the beginning time of your testing
Can anybody think how
can cause an array out of range critical error while backtesting?
It is a client doing the backtesting and apparently the history has been downloaded from elsewhere than the platform broker.
I thought that if data is missing, there is a mismatch reported and that bar is skipped.
Always check the "Bars" variable to make sure the index into Time[], High[], Low[], Close[], etc. will be valid or not.
This is especially important when running under the Strategy Tester with no "Use Date" limits, and during the first bar.
There will be no "mismatch" reported, because there is no mismatch. It simply just has the current bar data available.
Thanks,
I will check the value for Bars and see how it works out.
Start visual trading in the tester then you'll see the first bar...
;) there is always a first time ;)
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Can anybody think how
can cause an array out of range critical error while backtesting?
It is a client doing the backtesting and apparently the history has been downloaded from elsewhere than the platform broker.
I thought that if data is missing, there is a mismatch reported and that bar is skipped.