Trend Exhaustion Indicator for ThinkorSwim

Hi @BenTen - I'm testing this indicator on a 30D 10M bar chart on the /NQH20. I think I've only seen 1 arrow. I'm curious to ask if this works on the chart timeframe and symbol I'm using? Thanks!
 
@madeinnyc Since you mentioned that you saw one signal, it means the indicator is working. This indicator is known to produce rare signals.
 
How do you interpret the colors on the labels (white, yellow, cyan) and the arrow?

S110.png
I don't mean to resurrect an old thread, but what is that green/red box thing with the dashed lines? Looks interesting.
 
For the non VIP people here is a possible alternative. Make sure to set the time agg to your chart time.
https://tos.mx/mfbFUp

Cannot see the exhaustion code so no good idea how it compares.
Horserider,
1. Thanks for the share link - interesting code.
2. Where did get this Ema Cloud script?
3. Why did you say for non VIP members - try this - https://tos.mx/mfb. Is there something similar in the VIP section?
4. Did you intend for this cloud script to somehow replace the exhaustion code?
4. I took your code and made what I hope are some improvements.

# Found code at,
# https://usethinkscript.com/threads/trend-exhaustion-indicator-for-thinkorswim.333/
# Post #8, by Horserider.
# Original share link found was by Horserider = https://tos.mx/mfbFUp
# ===============================
# Notes.
# Suggested name = UTS_HorseRider_EmaCloud_1
# Rearraged code to flow better.
# Renamed vPeriod to be AggPeriod.
# Updated "Agg Period Choice Routine" - code by CG.
# Added chioce to turn off labels.
# Nice little code - TY horserider.
# ===============================
# Begin.
#MUST ADJUST TIME FRAME OF THIS FORMULA TO MATCH CHART;# Oiginal note.
declare upper;
# -------------------------------------------
input Force_Study_To_Use_Chart_Agg = yes; # code by CG.
def fstuca = Force_Study_To_Use_Chart_Agg;
input SeectedAggPeriod = AggregationPeriod.DAY;
def AggPeriod = if fstuca then GetAggregationPeriod() else SeectedAggPeriod;
# -------------------------------------------

input EMALength1 = 9; # default = 9.
input EMALength2 = 21; # default = 21.
input Display_Labels = yes;
input price = close;
input displace = 0;

def O = open (period = AggPeriod);
def H = high (period = AggPeriod);
def C = close (period = AggPeriod);
def L = low (period = AggPeriod);
def V = volume(period = AggPeriod);
# ===========================================
# It was nagging at me where I've seen this code routine that uses, V & HLC.
# It may be other placed too.
# www.floatchecker.com/blog/better-volume-indicators-for-thinkorswim

def SV = V * (H - C) / (H - L);
def BV = V * (C - L) / (H - L);

# ===========================================
def DL = if Display_Labels then 1 else 0;

AddLabel(yes * DL, "Buyer Vol Strong ", if high > high[1] and low > low[1] and BV*1.05 > SV then Color.GREEN else color.GRAY);

AddLabel(yes * DL, "Seller Vol Strong", if high < high[1] and low < low[1] and SV*1.05 > BV then Color.MAGENTA else color.GRAY);

AddLabel(yes * DL, "Price Strong ", if high > high[1] and high [1] > high[2] and low > low[1] and low[1] > low[2] then Color.GREEN else color.GRAY);

AddLabel(yes * DL, "Price Weak", if high < high[1] and high[1] < high[2] and low < low[1] and low[1] < low[2] then Color.MAGENTA else color.GRAY);

plot upper = ExpAverage(data = price[-displace], length = EMALength1);
upper.SetDefaultColor(Color.RED);
plot lower = ExpAverage(data = price[-displace], length = EMALength2);
lower.SetDefaultColor(Color.BLUE);
AddCloud(upper, lower);

def iscolormeBuy = upper >= lower;
def iscolormeSell = upper <= lower;

AddLabel(iscolormeBuy * DL, " EMA9 IS STILL GREATER THAN EMA21 :" , if UPPER >= LOWER + .1 then Color.GREEN else Color.BLACK);
AddLabel(iscolormeSell * DL, " SELL SIGNAL EMA9 LESS THAN EMA21: ", if UPPER <= LOWER - .1 then Color.MAGENTA else Color.BLACK);

# Unused left over code in original - https://tos.mx/mfbFUp
#def iscolormeWaiting = high<=high[1] and low >= low[1];
#AddLabel(yes, Concat (if iscolormeBuy then " EMA9 > EMA21: " else "", COLOR.BLACK));
#AddLabel(yes, Concat (if iscolormeSell then " EMA9 < EMA21: " else"", COLOR.BLACK));
#AddLabel (iscolormeWaiting, " WAITING FOR BEST TIMING: ", if high <= high[1] OR low >= low[1] then Color.YELLOW else Color.BLUE);
#AddLabel (iscolormeWaiting, " WAITING FOR BEST TIMING: ", IF high <=high[1] and low >= low[1]then Color.GRAY else Color.YELLOW);
#def agg = getAggregationPeriod(); # Unused in original horserider code.
#input AggPeriod = AggregationPeriod.day; # original was hour;now unsed.
# END.
 
Last edited:
Hey quick question! Is there a way to code this so the labels are the top are grey unless the statement is correct and then it changes color. No arrow.

Example if the bulls arent exhausted then the label is gray but as soon as they become exhaust the label on the top now turns green. and vice versa the bears arent exhausted then the label is gray and as soon as they become exhausted the label turns red.


Thanks!
 

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

Similar threads

Not the exact question you're looking for?

Start a new thread and receive assistance from our community.

87k+ Posts
315 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.
Back
Top