Is there a way I can check for an NAN error. Sometimes my script disappears and on the next bar reappears. In other words the indicators come and go. Does not happen often but sometimes. I wonder if that is related to the script being out of synch with WL at times as well.
Size:
Color:
QUOTE:
Sometimes my script disappears and on the next bar reappears
I think you mean that your indicators disappear...
First thing to do when that happens is to look at the bottom of the Editor for the runtime error, click on it, and see where it takes you.
Size:
Color:
Do a PrintDebug on your indicators while looping bar by bar. The debug window will most likely indicate a NaN somewhere.
Size:
Color:
Well, it happened again and I did check the bottom of the editor and so no runtime errors. As a matter of fact it was blank as if everything was fine. I hesitate to put debug statements because it is like looking for a needle in a haystack which could be anywhere. Just as a reminder, I never saw this in the previous version of WL. Since I uploaded the new version, it already happened about 3 times.
Size:
Color:
Could you point me where did I say to look at the "bottom of the editor"?
I'm sure the suggestion was to call PrintDebug in the loop to output the indicator's value on each bar to the Debug window.
As a quick alternative you might try mousing over the indicator's value on a bar and noticing its value in the Data window.
Size:
Color:
QUOTE:
Could you point me where did I say to look at the "bottom of the editor"?
You didn't, I did :)
Runtime errors are another reason that indicators (and panes and anythign else) won't show up in a chart, but it sounds like the NaN scenario here.
Size:
Color: