Adding # of Trades to Chart / Scanner


Category:
0
0

Hi Peter, really great content! Loving everything I’ve came across so far.

One thing I cannot locate is an scanner column / chart study that indicates # of trades. I see many on volume, but nothing that can actually display “1000 trades” or a tick of that. The closest I’ve came across to this info for TOS is the “TimeBasedTrades” study that Josiah developed.
https://www.youtube.com/watch?v=GjdFRgVlAV0

Would love any insight! Thanks!

Marked as spam
Posted by (Questions: 1, Answers: 1)
Asked on January 10, 2019 1:56 am
95 views
0
Private answer
Marked as spam
Posted by (Questions: 37, Answers: 4079)
Answered on January 10, 2019 5:06 pm
0

Hello Peter and thank you also for the email response as well. This is something I also would like to get going. My limitations, is that I only have 1-2 hours per day, and that is early am’s on weekends to be able to spend any time here…and thank you for this site again.

Jim

( at January 12, 2019 6:21 am)
0

Aparently if i edit my comment, it destroys the format of the comment, so I deleted the others and consolidating here, with the code for future people to reference

What I’m trying to do:
Chart Study 1
1) On the charts, plot out the # of trades per tick (1m:1day) – DONE
2) On the charts, sum the total volume for the day (including premarket) to display it – DONE

Chart Study 2)
1) Utilizing the same info as above, I want to be able to reference the same time/tick mark & compute an average of the past X days (10?). Since they are ticks, I was very lost on how to locate the specific tick mark for that time (say 9:45 am)

Scan:
Display the Total # of Trades for the Day – DONE

Images attached
Image 1: https://i.imgur.com/2b7GSp4.jpg
Image 2: https://i.imgur.com/7Ho1Oqx.jpg

Code for Total Trades Today + Current Trade Bar
declare lower;
declare zerobase;
def CurTickTrades = Fundamental(FundamentalType.TICK_COUNT);
def newDay = GetDay() GetDay()[1];
rec todaysTrades = if newDay then CurTickTrades else todaysTrades[1] + CurTickTrades;
AddLabel(ShowCurrentBar, “Current Trades: ” + CurTradeVolume, color.orange);
AddLabel(ShowCurrentBar, “Current Trades: ” + CurTickTrades, color.orange);

Code for Scan Column – # of Trades Today:
declare lower;
declare zerobase;
def CurTickTrades = Fundamental(FundamentalType.TICK_COUNT);
def newDay = GetDay() GetDay()[1];
rec todaysTrades = if newDay then CurTickTrades else todaysTrades[1] + CurTickTrades;
plot totaltrades = todaysTrades;

——————————————-
What’s missing from the above:
• A new volume bar study that grabs the average of the past 10x days and compares it to the current bar
– How would I be able to grab a ticket at a specific time, so I can compute that. Say 9:45 from 1 day ago, and from 2 days ago, etc

Thanks again!!

( at January 12, 2019 10:48 pm)
0

What you have requested here goes lightyears beyond the scope or level of complexity for solutions we provide at no charge here in the Q&A forum.

( at January 13, 2019 9:31 am)
0

No worries, all that’s missing that I need to figure out is how to locate a tick at a specific bar/time “X” days ago. Once I get it working I’ll post the code here to share with others seeking the same in the future.

( at January 13, 2019 10:11 am)
0

This is an interesting Post.

Can someone explain how tow get the chart label and watch-list column working for the code that was posted by Matt?

Code for Total Trades Today + Current Trade Bar
declare lower;
declare zerobase;
def CurTickTrades = Fundamental(FundamentalType.TICK_COUNT);
def newDay = GetDay() GetDay()[1];
rec todaysTrades = if newDay then CurTickTrades else todaysTrades[1] + CurTickTrades;
AddLabel(ShowCurrentBar, “Current Trades: ” + CurTradeVolume, color.orange);
AddLabel(ShowCurrentBar, “Current Trades: ” + CurTickTrades, color.orange);

Code for Scan Column – # of Trades Today:
declare lower;
declare zerobase;
def CurTickTrades = Fundamental(FundamentalType.TICK_COUNT);
def newDay = GetDay() GetDay()[1];
rec todaysTrades = if newDay then CurTickTrades else todaysTrades[1] + CurTickTrades;
plot totaltrades = todaysTrades;

( at January 23, 2019 1:14 am)