Custom Watchlist Columns Colored to Match Dots on TTM Squeeze Centerline
This video shows how to add a column to any watchlist displaying red or green to show you which stocks are in a squeeze. Additionally, this code will count the number of green dots since the last squeeze ended. Zeros mean the stock is in a squeeze. Values greater than zero indicate a stock that has exited the squeeze and is potentially ready for a big move. You can sort the watchlist by this column so you can spot the stocks that have just recently exited the squeeze.
Be sure to watch the video so you understand how to install it. This indicator compliments a previous video we published that displays the colors of the TTM Squeeze histogram in a watchlist. Use these together to create a ‘radar screen’ similar to those used in TradeStation. In a single glance you can see stocks that are ready to make a move and which direction the indicator is predicting.
John Carter’s TTM Squeeze is a licensed study available free on the Thinkorswim platform. This code does not expose any source code as it is fully protected by the Thinkorswim platform.
Learn More:
Click and drag interface to build custom watchlist columns. No code experience required:
Thinkorswim Condition Wizard Watchlist
DISCLAIMER: I AM NOT A CERTIFIED FINANCIAL ADVISOR AND NOTHING IN THIS VIDEO OR TEXT IS AN ADVERTISEMENT OR RECOMMENDATION TO BUY OR SELL ANY FINANCIAL INSTRUMENT. NOR IS THIS VIDEO OR TEXT INTENDED TO INSTRUCT YOU ON HOW TO MAKE BUY OR SELL DECISIONS USING ANY OF THESE INDICATORS.
*Thinkorswim is a chart analysis platform offered by TD Ameritrade: www.tdameritrade.com
TD Ameritrade provides financial services including the trading of Stocks, Futures, Options and Forex.
Please be sure to share this page with your friends and colleagues. Leaving comments below is the best way to help make the content of this site even better.
Watch the video, Thinkorswim Watchlist TTM Squeeze below:
input price = CLOSE;
input length = 20;
input nK = 1.5;
input nBB = 2.0;
input alertLine = 1.0;
def squeezeDots = TTM_Squeeze(price, length, nK, nBB, alertLine).SqueezeAlert;
def alertCount = if squeezeDots[1] == 0 and squeezeDots == 1 then 1 else if squeezeDots == 1 then alertCount[1] + 1 else 0;
plot data = alertCount;
data.AssignValueColor(if alertCount > 0 then Color.BLACK else Color.WHITE);
AssignBackgroundColor(if alertCount == 0 then Color.RED else Color.GREEN);
Hi Pete, could you help create a script for customs watchlist column, color coded for SMA or EMA crossovers? I am sure many will really appreciate this.
Check the Q&A forum. There have been numerous requests for something similar. If you don’t find one that fits your particular use case then post a new question in the forum.
Terribly sorry, English is my 2nd language, I have very hard tiem navigating in Q&A. I figured out 100% your instructions for customizing TTM Squeeze indicator and even managed to change colors in watchlist. Could you please help with scrit where I can get EMA or SMA crossover custom watchlist view, where I could in addition be able to change value of EMA and SMA for example 5 and 8 or 5 and 13 or 20 and 50 etc. Many thanks.
I do not provide custom solutions in the comments section of a video. There are only two places where I provide solutions. One is the Q&A forum, where I have provided well over 1,400 custom solutions to date. The other method is through my professional services, which I don’t advertise because I already have all the work I can get to. I am sorry that a language barrier prevents you from making use of our Q&A forum.
Additionally, if you want learn how to construct your own without knowing how to write a single line of code you will want to view the following video: https://www.hahn-tech.com/thinkorswim-condition-wizard-watchlist/
Hello, is there a way to add time frames to TOS in Watchlist Scritp writer menu. I can only install your TTM squeeze Dots indicator in my watch list with given list of time frames, what if I want to add customized time frame like 39 min, 78 minutes, 195 minutes. THIS WOULD HELP HUGELY, please help me solve this problem.
Sorry but no. There is no way in Thinkorswim to create custom aggregation periods from code. Those will have to be added by the developers of Thinkorswim. So if this is really crucial to your ability to trade successfully then be sure to contact TDA support to request they add custom aggregations to custom quotes.
Thank you Pete!
Hi Pete, I’m new here and learned tons of new stuff how to setup TDA on your website so far. I have question I copied the code and it works fine, but only shows green and red. As your video it actually shows the background color that matches TTM Squeeze Wave bar. Can you help me on this?
That’s a different video. And it’s not the TTM Wave but rather the TTM Squeeze Histogram. From the left hand side menu, you will find it is the one immediately above this one. You can use this direct link to get there: https://www.hahn-tech.com/thinkorswim-ttm-squeeze-watchlist/
Thank you so much Pete
nvm, I searched on your site and i find that you make another video on the color. Thank you 🙂
So now that you we learned from this video – thanks to your clear explaination – how to set up our platform, I know that you dont teach people how to trade but any advice or a link to where can we learn how to best use this strategy
(what is the best color combination need to look for between multiple timeframe to determine a trade timing)
Thank you
Sorry but I have no opinion on that topic.
Hello,
Could you please advise what I need to modify in this script so it will show a count in the red cells ( to know how many counts the stock has been in the squeeze )
Thank you
If you don’t find a solution in the Q&A Forum…
https://www.hahn-tech.com/ans/cat/watchlists/
… be sure to post a new request there.
Thank you for all your amazing help Pete.
I have an issue with a custom code I am writing up.
def Buy = RSI < 30;
def StrongBuy = RSI 70 ;
def StrongSell = RSI >75;
def NoBuy = not Buy and not StrongBuy and not Sell and not StrongSell;
I know there are other ways around this. But really want to use the feature “not” due to some of my other code being alot more complicated and not as easy to code to not fall under 70 and above 30.
Thank you.
Exclamation mark immediately in front of any true/false value serves in pace of “not”. So “!Buy” means Buy is not true.
Thank you for the content Pete, its always appreciated.
I put the squeeze dots on my watch list. I noticed that sometimes the watch list shows that the stock is in a squeeze and when the dots are green on the chart. I double checked the time on the chart with the time on the watch list indicator and it matches. Im thinking that the stock is squeezing but it hasn’t closed yet. Any idea?
Thank you.
See if this solution posted here clears thing up: https://www.hahn-tech.com/ans/hourly-adx-watchlist-not-matching-hourly-chart/
Worked Perfect. Thank you.
I get only one green column with numerical values to the right of the column.
I just tested the code and it’s working fine. Make sure you have set the correct time frame and copied the code correctly. If you still cannot get expected results then post a new question in our Q&A forum.
Understand now, but it would be helpful for you to explain each of the columns and when and where they were added, and what the names of them represent. Adding this particular column is only a part of the picture.
Hmmm… that probably means you need to watch the other video. This one covers the color of the dots on the centerline of the squeeze. There is another video that covers the histogram colors. https://www.hahn-tech.com/thinkorswim-ttm-squeeze-watchlist/