Relative Volume Strategy and Momentum Scanner for ThinkorSwim

@Sonny @BenTen Thanks to everyone for their input, knowledge and guidance regarding the RVI watchlist. I agree that the RVI code assists in making strategic choices when trading. I was searching for code that I could manipulate when scanning for RVI instead of a watchlist. I then decided to use @Sonny's code to create a scan for RVI; resulting in two RSI scans. The first code is for tickers with a RVI >=2; and the other is for tickers with a RVI <2. This helps to narrow down my search enabling me to focus on the high RVI. I included low float shares, vol of 1m etc within the scan.

Additionally, as some members indicated, these tickers also appear in my momentum and premarket and gapper's scan. I tend to trade the penny stocks at this time (.05 to 3.00 or 5.00). The scan can be altered if looking to trade large caps, larger floats etc. Upon executing the scan I simply check my watchlist and select the tickers with catalysts. I have the VWAP, 9EMA etc on my chart and these along with the Fibonacci retracement helps a lot.

I also created an alert which alerts when tickers are removed or added to the watchlist/scan.

Please see below the scan as well as a pic of the scanner (this is from today's trading session). Thanks once again to everyone who has contributed to my growth as I continue my trading journey on this forum.

Code:
#Relative Volume High;
def x = Average(volume, 60)[1];
def v = volume;
def r = Round((v/x),1);
def rvi = r >= 2;
plot scan = rvi;

RVIscan.jpg


Code:
#Relative Volume Low;
def x = Average(volume, 60)[1];
def v = volume;
def r = Round((v/x),1);
def rvi =  r < 2;
plot scan = rvi;

RVIscanlow.jpg
 

Ben's Swing Trading Strategy + Indicator

I wouldn't call this a course. My goal is zero fluff. I will jump right into my current watchlist, tell you the ThinkorSwim indicator that I'm using, and past trade setups to help you understand my swing trading strategy.

I'm Interested

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

@BonBon Thanks for your update. I was also starting to use the Fibonacci Retracement to find entry positions, but it would mostly blow past my support levels. Anyway you can send a pic a pic and explain on how you use your indicators while watching a ticker that pops up on this scanner?
 
@BonBon Thanks for your update. I was also starting to use the Fibonacci Retracement to find entry positions, but it would mostly blow past my support levels. Anyway you can send a pic a pic and explain on how you use your indicators while watching a ticker that pops up on this scanner?

@Gabrielx77 you are welcome. There are several ways I use the Fibonacci retracement. If it is a stock that gapped up I would wait until it retraces to the 78.6. levels and wait for the buy signal (I have found that the 78% levels is near the stock's previous support level).

For momentum stocks, I would wait for a retracement no further than the 50% or 66% levels. I have found that these stocks that retrace below the 66% can simply be a pump. I also consider the catalyst when drawing the retracement lines as some tickers may only retrace to the 28% or 36% retracement levels if its a very strong catalyst. I also utilize other technical analysis to help make decisions regarding the trade.
 
@Gabrielx77
As you can see DTSS had the highest RVI on my scan. This is the scan's watchlist. DTSS was one of the main movers in the premarket with a high RVI but it opened lower than the premarket price. The down arrow shows that the stock has started to retrace. As this stock gapped up tremendously from its previous day's close I assumed it would retrace to the 78% levels. As you can see it retraced throughout the day. It can reach the 78% retracement levels (or near it) and then gap up once again. However in this scenario I would not take the trade but wait until it retraces and look for a buy signal (the up arrow after the retracement to the previous day's levels. This arrow is part of the trendpainter courtesy of @BenTen). To the right there are also support and resistance lines as well. This code was obtained in this forum as well.

Example-DTSS.jpg



This is the second example

MARA also had a high RVI. It was the 5th highest on my scan/watchlist. However, based on the buy signal (arrow on the chart), VWAP and the strong buy trend this was a better trade. It only retraced to the 38% level and went as high as $4.79. (reminder, the fib retracement was done at the opening. I would have to re-draw the fib retracement reflecting the $4.79 price to get an accurate retracement level.


Example-Mara.jpg
 
@BonBon This looks good. I have been trying to implement the Fib Retracements on my gapers to have a more concrete approach for a entry and exit point, but I keep running into trouble when it comes to knowing which stock will bounce and which will run straight through. I draw my support lines, look at trend and I use my RSI to help determine when a good entry point is. I need to look more at the pre-market gapers using the RV1 indicator. Thank you for the input, I'll let you know what I do tomorrow.
 
@BonBon This looks good. I have been trying to implement the Fib Retracements on my gapers to have a more concrete approach for a entry and exit point, but I keep running into trouble when it comes to knowing which stock will bounce and which will run straight through. I draw my support lines, look at trend and I use my RSI to help determine when a good entry point is. I need to look more at the pre-market gapers using the RV1 indicator. Thank you for the input, I'll let you know what I do tomorrow.

Here's my method:
1. Take the top RV1 stocks.
2. Take the pre-market high and lows. I only consider stocks within the top 50% of this range at market open. Sometimes I may look to the top 61.8% range. The reason for this is you want stocks that have the highest change of breaking above the pre-market high. Those are the runners. If a stock has too far to go to reach the pre-market high, it likely won't break that level.
3. Generally, VWAP is hanging out in the area just above the consolidation zone. Prioritize these.
4. Look for volume + price divergence.

You'll find there's only one, maybe two, that meet this criteria each morning.
 
Here's my method:
1. Take the top RV1 stocks.
2. Take the pre-market high and lows. I only consider stocks within the top 50% of this range at market open. Sometimes I may look to the top 61.8% range. The reason for this is you want stocks that have the highest change of breaking above the pre-market high. Those are the runners. If a stock has too far to go to reach the pre-market high, it likely won't break that level.
3. Generally, VWAP is hanging out in the area just above the consolidation zone. Prioritize these.
4. Look for volume + price divergence.

You'll find there's only one, maybe two, that meet this criteria each morning.
Love this scan and logic alot. Got the RVI columns etc but do you have the Arrow with thumbs up or down and Trend Script ?
 
Last edited:
at what time do you categorize the rv1s ! " take the top RV1" stocks as Gin09 wrote , how many do you watch and what time do you run a scan? thanks.
 
at what time do you categorize the rv1s ! " take the top RV1" stocks as Gin09 wrote , how many do you watch and what time do you run a scan? thanks.

I just use a watchlist and when one pops up I quickly scan to see if it’s greater than 50% of the pre-market move. If not I generally ignore it
 
@Ginu09, @axlerod

Please go to my post in Trend Painter thread to see the code that I created for the trendpainter watchlist. @BenTen created the original trendpainter code which is on the chart and I adapted it to create the watchlist. Please let me know if you want the code for the arrows which are the buysignals (arrows) that are on the chart.
 
Last edited by a moderator:
I just use a watchlist and when one pops up I quickly scan to see if it’s greater than 50% of the pre-market move. If not I generally ignore it
This is a good way to look at it. What tickers did were you eyeing out today right before market open?
 
So after reading through everything slightly confused.

I have 2 scripts for RV1

This one referring to this post https://usethinkscript.com/threads/color-coded-watchlist-columns-for-thinkorswim.2977/post-28578

def isRollover = GetYYYYMMDD() != GetYYYYMMDD()[1];
def beforeStart = GetTime() < RegularTradingStart(GetYYYYMMDD());
def vol = if isRollover and beforeStart then volume else if beforeStart then vol[1] + volume else Double.NaN;
def PMV = if IsNaN(vol) then PMV[1] else vol;
def AV = AggregationPeriod.DAY;
def x = Average(Volume(period=AV)[1],60);
def y1 = Round((PMV/x),2);
def L = Lg(y1);
def p = if L>=1 then 0 else if L>=0 then 1 else 2;
def y2 = Round(y1,p);
plot z = y2;
z.assignValueColor(if z>=10 then color.CYAN else if z>=1 then createcolor(255,153,153) else createcolor(0,215,0));


The the original code on page 1 - https://usethinkscript.com/threads/color-coded-watchlist-columns-for-thinkorswim.2977

def x = Average(volume, 60)[1];
def v = volume;
plot r = Round((v/x),1);
r.assignValueColor(if r >= 20 then color.CYAN else if r>=5 then createcolor(255,153,153) else createcolor(0,215,0));



Which one do I use? Or Do i use both and one called Pre Market RV1 and the other RV1 ?

Thank you very much also the other columns you posted on page 1 I set all to 1d time is that correct? @sunny
 
Focus on stocks that appear on the scan before 10:15am and track them. If a stock's volume is not 1,000,000 by 9:45am, then it is not worth tracking. Today, BOXL and BKYI showed up and had decent spikes.
Be great if we can have it so they fall off if volume doenst hit 1mill by that time. I know we can add it into the code just gotta figure out exactly how.
 
@Ginu09, @axlerod

Please go to my post in Trend Painter thread to see the code that I created for the trendpainter watchlist. @BenTen created the original trendpainter code which is on the chart and I adapted it to create the watchlist. Please let me know if you want the code for the arrows which are the buysignals (arrows) that are on the chart.
Ya just noticed that becasue the thumbs I tried didn't work for me but I also noticed in the picture above the THUMBS for example MARA (picture 1) had a THUMBS UP but said BEARISH in red. Hate to ask but could you post the link for the THUMBS portion and what time frame do you have that set too? Thank you very much god bless you all for your knowledge and wisdom! Much appreciated!
 
Do you use any custom such as

def x = Average(volume, 60)[1];
def v = volume;
def r = Round((v/x),1);
def rvi = r >= 2;
plot scan = rvi;

OR

plot scan = close >= (open*1.04);
 
@Gabrielx77
As you can see DTSS had the highest RVI on my scan. This is the scan's watchlist. DTSS was one of the main movers in the premarket with a high RVI but it opened lower than the premarket price. The down arrow shows that the stock has started to retrace. As this stock gapped up tremendously from its previous day's close I assumed it would retrace to the 78% levels. As you can see it retraced throughout the day. It can reach the 78% retracement levels (or near it) and then gap up once again. However in this scenario I would not take the trade but wait until it retraces and look for a buy signal (the up arrow after the retracement to the previous day's levels. This arrow is part of the trendpainter courtesy of @BenTen). To the right there are also support and resistance lines as well. This code was obtained in this forum as well.

Example-DTSS.jpg



This is the second example

MARA also had a high RVI. It was the 5th highest on my scan/watchlist. However, based on the buy signal (arrow on the chart), VWAP and the strong buy trend this was a better trade. It only retraced to the 38% level and went as high as $4.79. (reminder, the fib retracement was done at the opening. I would have to re-draw the fib retracement reflecting the $4.79 price to get an accurate retracement level.


Example-Mara.jpg
What is this Volume study?
 

New Indicator: Buy the Dip

Check out our Buy the Dip indicator and see how it can help you find profitable swing trading ideas. Scanner, watchlist columns, and add-ons are included.

Download the indicator

Not the exact question you're looking for?

Start a new thread and receive assistance from our community.

87k+ Posts
310 Online
Create Post

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