Candle Wick Sentiment Indicator for ThinkorSwim

M

mashume

Active member
VIP
This gives bullish / bearish sentiment by looking at wick length vs body size. Potential pivots are indicated with green or red dots.



Code:
# Experiment # 3
# Candle Wick Sentiment Indicator
# Seth Urion
# November 2019

declare lower;

input reversal = 33;
input trend_length = 5;

def total = high - low;
def upper_candle = high - Max(open, close);
def lower_candle = Min(open, close) - low;
def trend_mult = if close >= open then 1 else -1;

plot zero = 0;
zero.SetLineWeight(1);
zero.AssignValueColor(Color.WHITE);
zero.SetStyle(Curve.MEDIUM_DASH);

def Upper_Sentiment = if total != 0 then 100 - ((upper_candle / total) * 100) else 0;
def Lower_Sentiment = if total != 0 then -100 + (( lower_candle / total) * 100) else 0;

plot Trend = ExpAverage(Upper_Sentiment + Lower_Sentiment, length = trend_length);
Trend.SetLineWeight(3);
Trend.AssignValueColor(Color.WHITE);

plot UpperWickReversal = if Upper_Sentiment <= reversal and Upper_Sentiment != 0 then Upper_Sentiment else Double.NaN;
UpperWickReversal.SetPaintingStrategy(PaintingStrategy.POINTS);
UpperWickReversal.SetLineWeight(4);
UpperWickReversal.AssignValueColor(Color.RED);

plot LowerWickReversal = if Lower_Sentiment >= -reversal and Lower_Sentiment != 0 then Lower_Sentiment else Double.NaN;
LowerWickReversal.SetPaintingStrategy(PaintingStrategy.POINTS);
LowerWickReversal.SetLineWeight(4);
LowerWickReversal.AssignValueColor(Color.Green);

I got tired of looking at candles and wondering if they should be telling me something. This is not perhaps the clearest indicator and should not be used in isolation, but the turning points can be good indications that something is about to happen.

Happy Trading!
 
M

mashume

Active member
VIP
@marine, I generally use RSI in Laguerre time with Fractal Energy for entry points. This is my 'early warning' system to potential changes in the mood of the market.

I can walk you through the day illustrated above and what each signal might mean to me...
  1. The green dot just after 7:00 (remember I'm on a tick chart) with a generally positive sentiment tells me that the bears are losing control of the trade.
  2. The sentiment remains somewhat negative even as price rises through about 9:00 telling me that there is either some profit taking, or some reluctance to move higher. This sentiment is reversed just after 9:00 when the trend crosses into positive territory and price then rockets up.
  3. The red dot at 9:45, before the downward move, alerts me that there may be some move to the downside as the bulls have lost control of that candle.
  4. Bears lose control themselves just before 10:00 and the price is free to move higher again.
  5. Positive sentiment after 11:15 paired with decreasing prices sends a BIG warning sign that some downturn is on the way.
  6. The bulls lose control at the red dot at 12:00, setting off (but preceding) the precipitous plunge over lunch between 12 and 12:30.
This is how I read it. It's not generating buy and sell signals (other indicators do that well). It does give me some sense of the tug-of-war between bears and bulls on a candle-by-candle basis.

Change up the smoothing length, or the threshold (this sets the point at which dots are drawn).

The idea for the indicator was born after reading this article:
https://admiralmarkets.com/analytic...s-a-key-shortcut-during-forex-and-cfd-trading

Hope that helps you understand a bit of what this one is showing you. As always, your read of the market is your own.

Happy Trading
 

Similar threads

Top