Bollinger Bands and Stochastic Scalping Indicator for ThinkorSwim

BenTen

BenTen

Administrative
Staff
VIP
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;

bullish.SetPaintingStrategy(PaintingStrategy.BOOLEAN_ARROW_UP);
bullish.AssignValueColor(Color.GREEN);

bearish.SetPaintingStrategy(PaintingStrategy.BOOLEAN_ARROW_DOWN);
bearish.AssignValueColor(Color.RED);

Shareable Link


Credit:
 
Last edited:
H

Heisenberg

New member
Hello Ben, I installed this indicator but the candles aren't on the chart anymore. Do you have any idea why?

 
Last edited:
BenTen

BenTen

Administrative
Staff
VIP
@Heisenberg The candles or the arrows?

 
Last edited:
S

San

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

 
Last edited:
BenTen

BenTen

Administrative
Staff
VIP
@San Ahh I see, go into the indicator's setting and untick "Show Plot" for RATING.

 
Last edited:
S

San

New member
VIP
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:
BenTen

BenTen

Administrative
Staff
VIP
@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:
S

San

New member
VIP
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:
BenTen

BenTen

Administrative
Staff
VIP
@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:
S

San

New member
VIP
Thanks for your updates. Yes i see the arrow and thanks for your quick response...

 
Last edited:
J

jan_angel

New member
VIP
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:
BenTen

BenTen

Administrative
Staff
VIP
@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:
T

theodorejuliano

New member
VIP
I have applied the script to SPX and am not seeing any signals on any intraday timeframe.
 
markos

markos

Active member
VIP
It probably won't work on anything that does not have volume because it's calling the Money Flow ind. which I beleive uses Volume.
 

Top