Bollinger Bands and Stochastic Scalping Indicator for ThinkorSwim


Staff member
If you like to trade or scalp on the shorter time frame such as the 2m, 5m, and 15m, this indicator is for you. The Scalper indicator generates buy and sell signals based on the Bollinger Bands, Stochastic Full, RSI, MFI, and IMI (Intraday Momentum Index).



thinkScript Code

Rich (BB code):
# Scalper
# Drew Griffith

#hint: Intraday Day mean reversion strategy. Used on 2min charts.

declare upper;

input price = close;
input BBlength = 12;
input FSOkperiod = 10;
input FSOdperiod = 6;
input FSOslowingperiod = 6;
input FSOob = 80;
input FSOos = 20;
input RSIlength = 12;
input RSIob = 70;
input RSIos = 30;
input MFILength = 12;
input MFIob = 80;
input MFIos = 20;
input IMILength = 12;
input IMIob = 70;
input IMIos = 30;

def BBupper = BollingerBands(length = BBlength).UpperBand;
def BBlower = BollingerBands(length = BBlength).LowerBand;

# StochasticFull
def FSO = StochasticFull("k period" = FSOkperiod, "d period" = FSOdperiod, "slowing_period" = FSOslowingperiod);

def RSI = RSI(length = RSIlength);

def MFI = MoneyFlowIndex(length = MFILength);

def IMI = IntradayMomentumIndex(length = IMILength);

plot bullish = close <= BBlower and RSI <= RSIos and FSO <= FSOos and MFI <= MFIos and IMI <= IMIob;

plot bearish = close >= BBupper and RSI >= RSIob and FSO >= FSOob and MFI >= MFIob and IMI >= IMIos;

#plot RATING = if bullish then 1 else if bearish then .5 else 0;



Shareable Link

Video Tutorial

Last edited:

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

Ben, After added this script. The chart shows shrink not able to see the candle but i see the arrows.

Last edited:
@San Ahh I see, go into the indicator's setting and untick "Show Plot" for RATING.

Last edited:
Ben, My bad I looked arrows on other indicator not TTM_Scalper. But after untick "Show Plot" for RATING able to see the candle NOT arrow.

I have noticed in Indicator Bullish and Bearish tab "color: This plot's colors are dynamically set" I am not sure this is default because usually we see some color!

Last edited:
@San The indicator don't often give you signals and the arrow's colors are set to default (down = red and up = green). This indicator will work on intra-day only. So from 1m to 15m max.

Last edited:
I have verified last 5 days chart for Amzn with 1mts/5mts/15mt but some reason I don't see any arrow for Feb15th.

Last edited:
@San Do you see any arrows on the chart at all? If you do, then that means there was no signal given for AMZN on that specific day.

Last edited:
Thanks for your updates. Yes i see the arrow and thanks for your quick response...

Last edited:
Hello BenTen...first thank you for posting this script. I am having the same issue as San. Everytime i change the symbol, the chart shrinks

Last edited:
@jan_angel Please see my reply above regarding the “Show Plot” option for RATING. In addition, you can also left click on the chart and unselect Fit Studies.

Last edited:

Thank you! I have noticed if the trigger happens very early in the trading day, it could signal a reverse in the opposite direction for the rest of the trading day.

Also, i noticed if you wait for a double red or green bar in the signal direction, you can better "guesstimate" the reversal long term.

Just early observations. I am trying to find a good baseline / confirmation indicator to help support triggers.
Hi Ben I feel like a kid in a candy store with all of these indicators, I'm new to trading and to this site. Anywho I copied and pasted the short link of the scalper into TOS. I tried it in on demand and Scalper gives the green arrows but not the red arrows. I only get the red arrows in pre market. Thanks in advance.
@VM23 Welcome, glad you are enjoying the forum. Posters add so much, so often, I feel like a kid in a candy store, every day :) .
Unfortunately, TOS paper trading has some particularities. Which for the most part, have no workarounds. If you want more detail, you will have to call TOS customer support. Please come back and share what they had to say.
Last edited:

Similar threads

Not the exact question you're looking for?

Start a new thread and receive assistance from our community.

87k+ Posts
259 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.