I don't know how many of you guys follow Brett Steenbarger's blog. But he has been talking about this adjusted cumulative TICK indicator. I finally took the time to attempt to reproduce that. The graphs looks similar, but still off by a tiny bit.
Here's the code:
def previousdaysaverage = Average(((high("$tick") + low("$tick") + close("$tick")) / 3), 395);
plot data = TotalSum(((high("$tick") + low("$tick") + close("$tick")) / 3)) / 100 - previousdaysaverage;
Got this graph from markettells.com
Subscribe to:
Post Comments (Atom)
6 comments:
I really like Bretts blog and his indicators so thank you for this one. Great work!
Btw. So you use the $trin-$trin 1 min when charting and not $tick symbol?
hi
here is my script for the cumulative tick, it is unadjusted but it allows u to use multi-days TOS chart. This is because it is not using the TotalSum function.
Could you please see whether my scripts are correct? I am stil pretty new to thinkscript.
Gooi fr Singapore
def avgtick = ((high("$tick") + low("$tick") + close("$tick")) / 3);
rec data = if(secondsfromTime(mkt_open)==0, 0, data[1]+avgtick);
plot d = data;
declare lower;
plot zeroline = 0;
hey just tried this indicator out and I can't seem to get it to plot in TOS. Any trick to it in terms of the days you need to show, etc.? I'm trying it on a 3m chart and I just get a flat line. Any thoughts greatly appreciated.
question - why the /100 in final line of code?
Thank you
I think there were some errors in the logic behind those calculations as well as in Anon's version above, so I put together a working version here. It includes both the cumulative tick, and the cumulative adjusted tick indicator that Brett Steenbarger talks about. One thing to note is that the cum adjusted tick indicator only works when "show extended hours" is turned off.
Post a Comment