♥ 0 |
Hello Pete, How can I make an arrow signal for the 5-minute chart to show only one arrow (either the black OR red arrow) if the totalDollarVolume > $100K to be Color.Black Down Arrow and if the totalDollarVolume > $200K to be Color.Red Down Arrow Thanks RESOLVED
Marked as spam
|
Please log in to post questions.
You did give me a code before for the dollar volume as totalDollars = volume * close
Can we use this code for that?
Btw since you mentioned the # of trades as well. Where can I find that in TOS? Or the coding for that. Since I can’t seem to find it. Or should I post a new question for that?
That other code is meant to read data at the one minute time frame to decrease the degree of error in the value. In this request, you want to read data from the 5 min chart. We cannot get 1 min data into a 5 min chart.
For the number of trades, search this forum using the word: TICK_COUNT
You can read the official documentation here: http://toslc.thinkorswim.com/center/reference/thinkScript/Constants/FundamentalType/FundamentalType-TICK-COUNT.html
def aproximateDollarVolume = volume * close;
plot signalOne = aproximateDollarVolume > 100000 and aproximateDollarVolume <= 200000;
signalOne.SetPaintingStrategy(PaintingStrategy.BOOLEAN_ARROW_DOWN);
signalOne.SetDefaultColor(Color.BLACK);
signalOne.SetLineWeight(3);
plot signalTwo = aproximateDollarVolume > 200000;
signalTwo.SetPaintingStrategy(PaintingStrategy.BOOLEAN_ARROW_UP);
signalTwo.SetDefaultColor(Color.RED);
signalTwo.SetLineWeight(3);
If that’s the case. Then what would be the code for the 1min timeframe?
Thanks for the “trades” link.
I have updated my response to include code for the approximate dollar volume. You can use this on any time frame but the values are not exact on any time frame.
Thanks Pete. You are always helpful.