Simple Options Volume Indicator for ThinkorSwim

switchfire

Member
Hello,

I've built a very basic study to show the volume of up to 2 specific chosen options. I don't know how useful this might be. If anyone has any suggestions or ideas I'm willing to listen. It would be cool if there were a way to sum of the volume of all calls or puts for a specific expiration. Or maybe add the volume for entered strike + 3 strikes above or below. I don't know if any of this is possible. Anyways just thought I'd share.

Code:
#Option_Vol - Simple Volume Histagram for up to 2 Options
#Created by Switchfire
#v1.0 08FEB2020


declare lower;

input Option1 = "";
input Option2 = "";

plot Vol1 = volume(Option1);
plot Vol2 = volume(Option2);

Vol1.SetPaintingStrategy(PaintingStrategy.HISTOGRAM);
Vol2.SetPaintingStrategy(PaintingStrategy.HISTOGRAM);
Vol2.SetDefaultColor(GetColor(5));

#End Script

https://tos.mx/RIIAst4
This shows the calls (blue) and puts (red) for Monday, 10 Feb 2020 332c/p

unknown.png

(i've done a simple modification to the plot which anyone can apply in settings)
 
Last edited:

Join useThinkScript to post your question to a community of 21,000+ developers and traders.

Is it possible in TOS to have 3 strike prices and so you don't need to manually pick the strike, a command that says something along the lines of "choose current ATM strike, choose 1 strike OTM, choose 2 strikes OTM)... so if SPX is trading 3334, for example, it chooses the next closest expiration and the 3335, 3340 and 3345 strikes?
 
There is a thinkscript command "GetATMoption", which would theoretically help with this, but I can't seem to get it to work, even using the basic examples given on the site. You can also call adjacent options using GetNextITMOption and NetNextOTMOption, which could perhaps accomplish your idea.

Maybe you'll have better luck: GetATMoption - thinkorswim

Is it possible in TOS to have 3 strike prices and so you don't need to manually pick the strike, a command that says something along the lines of "choose current ATM strike, choose 1 strike OTM, choose 2 strikes OTM)... so if SPX is trading 3334, for example, it chooses the next closest expiration and the 3335, 3340 and 3345 strikes?
 
Is it possible in TOS to have 3 strike prices and so you don't need to manually pick the strike, a command that says something along the lines of "choose current ATM strike, choose 1 strike OTM, choose 2 strikes OTM)... so if SPX is trading 3334, for example, it chooses the next closest expiration and the 3335, 3340 and 3345 strikes?

That would be pretty cool. I tried to play around with GetATMOption, but i don't have the experience or skills with thinkscript to know if it's plausible
 
@switchfire Great work, this is great!

Is it possible to make this easier so we don't have to manually enter the strike codes?

For example, maybe it can automatically grab the ATM call and puts based on the most recent option expiry (weeklies for example) for the current symbol... that would save loads of time, as we constantly switch between companies - thanks!
 
Would it be possible to make a version of this script that takes into account ALL p/c regardless of strike and expiration?
 
@spm009 your best bet would be to just use Interactive Brokers, the platform does that (aggregates all call and put volume), and it does it easily without using a huge amount of memory... In my experience, the plots aren't very valuable while day trading... there's many false signals

Interactive Brokers also does a good job of showing volume and open interest for each strike, separated by expiry

I would post a screen shot but the forum doesn't have an option

What's great about this indicator for TOS is that you can customize the plot for a particular strike you're interested in, which could be more valuable.
 
This is such a good indicator and fits perfectly with my strategy. I was wondering if there was a way to scan for volume spikes above a given number? or if it was possible to scan for relative volume? Thank you!
 

Similar threads

Not the exact question you're looking for?

Start a new thread and receive assistance from our community.

87k+ Posts
307 Online
Create Post

Similar threads

Similar threads

The Market Trading Game Changer

Join 2,500+ subscribers inside the useThinkScript VIP Membership Club
  • Exclusive indicators
  • Proven strategies & setups
  • Private Discord community
  • ‘Buy The Dip’ signal alerts
  • Exclusive members-only content
  • Add-ons and resources
  • 1 full year of unlimited support

Frequently Asked Questions

What is useThinkScript?

useThinkScript is the #1 community of stock market investors using indicators and other tools to power their trading strategies. Traders of all skill levels use our forums to learn about scripting and indicators, help each other, and discover new ways to gain an edge in the markets.

How do I get started?

We get it. Our forum can be intimidating, if not overwhelming. With thousands of topics, tens of thousands of posts, our community has created an incredibly deep knowledge base for stock traders. No one can ever exhaust every resource provided on our site.

If you are new, or just looking for guidance, here are some helpful links to get you started.

What are the benefits of VIP Membership?
VIP members get exclusive access to these proven and tested premium indicators: Buy the Dip, Advanced Market Moves 2.0, Take Profit, and Volatility Trading Range. In addition, VIP members get access to over 50 VIP-only custom indicators, add-ons, and strategies, private VIP-only forums, private Discord channel to discuss trades and strategies in real-time, customer support, trade alerts, and much more. Learn all about VIP membership here.
How can I access the premium indicators?
To access the premium indicators, which are plug and play ready, sign up for VIP membership here.
Back
Top