Up until yesterday my code ran for a week or so with not problems. I forgot to extend it’s expiration date so today when I saw that I wanted to restart it. I then got a message saying, that “the historical data is insufficient to calculate at least one indicator” and to increase the number of preloaded bars using the DEFPARAM PRELOADBARS = X”.
As I said I never changed anything before it stopped working. The first part of my code looks like this:
After that comes the conditional parts of the code (what triggers an enter and exit position). I tried putting in a space on both sides of the equal sign. I also tried changing the number from 20000 to anything between 10000 and 200000. Nothing helped. I’m using version 10.3 and that didn’t change over the last couple of days.
Do you guys have any suggestions to what’s happened and how I can fix it?