I've exhausted my brain trying to figure this out. It works on the chart...sort of. I just copy and pasted the code from the ToS tutorial on data not connected to a chart. It had me attach the bid and ask price to the close price. Good enough for that I guess. I defined a plot variable spread in the study, but the scanner doesn't seem to call the variable correctly. Can see it plotted on the chart though. Here's the thinkscript code:
Here's the thinkscript version of the condition:
I didn't actually manually type that in. I used the "Condition Wizard." Anyone tell me what I'm doing wrong?
Code:
plot ask = close(priceType = "ASK");
plot bid = close(priceType = "BID");
plot spread = ask - bid;
Here's the thinkscript version of the condition:
Code:
BidAskSpread()."spread" is less than 0.5
I didn't actually manually type that in. I used the "Condition Wizard." Anyone tell me what I'm doing wrong?