@BTExpress I don't think you did it correctly. Supertrend shouldn't be equal to 1 as a condition. Modify that specific scan > switch over to the thinkScript editor and then paste the given scanner code.
Join useThinkScript to post your question to a community of 21,000+ developers and traders.
I tried each of those 4 statements at a time but didn't get any result. It didn't work.I use the scanner each trading day. The code is written to show new signals
#plot SuperTrendUP = if ST crosses below close then 1 else 0;
plot SuperTrendDN = if ST crosses above close then 1 else 0;
If you want to show active signals use the following;
plot SuperTrendUP = if ST < close then 1 else 0;
plot SuperTrendDN = if ST >close then 1 else 0;
AddChartBubble(close crosses below ST, low[1], low[1], color.Dark_Gray);
AddChartBubble(close crosses above ST, high[1], high[1], color.Dark_Gray, no);
# Mobius
# SuperTrend
# Chat Room Request
input AtrMult = 1.0;
input nATR = 4;
input AvgType = AverageType.HULL;
input PaintBars = yes;
def ATR = MovingAverage(AvgType, TrueRange(high, close, low), nATR);
def UP = HL2 + (AtrMult * ATR);
def DN = HL2 + (-AtrMult * ATR);
def ST = if close < ST[1] then UP else DN;
plot SuperTrend = ST;
SuperTrend.AssignValueColor(if close < ST then Color.RED else Color.GREEN);
AssignPriceColor(if PaintBars and close < ST
then Color.RED
else if PaintBars and close > ST
then Color.GREEN
else Color.CURRENT);
def bullish = close crosses below ST;
def bearish = close crosses above ST;
# Alerts
Alert(bullish, " ", Alert.Bar, Sound.Chimes);
Alert(bearish, " ", Alert.Bar, Sound.Bell);
# End Code SuperTrend
AssignPriceColor(if PaintBars and close < ST
then Color.RED
else if PaintBars and close > ST
then Color.GREEN
else Color.CURRENT);
Thread starter | Similar threads | Forum | Replies | Date |
---|---|---|---|---|
Archived: TMO True Momentum Oscillator | Indicators | 346 | ||
Archived: RSI Divergence Indicator | Indicators | 131 | ||
Archived: Opening Range Breakout | Indicators | 340 | ||
S | Smart Supertrend For ThinkOrSwim | Indicators | 13 | |
M | SuperTrend Oscillator [LUX] For ThinkOrSwim | Indicators | 7 |
Start a new thread and receive assistance from our community.
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.
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.