My Pivot Line Analysis Market Sentiment indicator (https://www.prorealcode.com/prorealtime-indicators/pivot-line-analysis-market-sentiment-indicator/) got me thinking. Why not use pivot line calculations to create pivot points for every candle instead of just daily pivot lines. Then we can compare the current candle’s lines with the previous candle’s and get an idea of immediate market sentiment.
This simple indicator helps us see immediate market sentiment at a glance. It can be applied on any time frame and any market.
- Rising Pivots. If this candle’s R1 is higher than the last candle’s R1 and this candle’s S1 is higher than last candle’s S1 then sentiment is bullish.
- Falling Pivots. If this candle’s R1 is lower than last candle’s R1 and this candle’s S1 is lower than last candle’s S1 then sentiment is bearish.
- Outside Pivots. If this candle’s R1 is higher than last candle’s R1 and this candle’s S1 is lower than last candle’s S1 then the bulls and bears had a big fight resulting in increased volatility and the market may be at a point of indecision.
- Inside Pivots. If this candle’s R1 is lower than last candle’s R1 and this candle’s S1 is higher than last candle’s S1 then the bulls and bears had a very evenly matched fight and the market may be at a point of indecision.
A green bar indicates that this is a bullish candle.
A red bar indicates that this is a bearish candle.
A long blue bar indicates that this candle was a more volatile candle.
A short blue bar indicates that this candle was a candle of indecision.
The indicator bar below each candle refers to the sentiment of the candle immediately above it.
If the blue bar is raised then it indicates that the bulls came out slightly on top.
If the blue bar is lowered then it indicates that the bears came out slightly on top.
The blue bars are of the most interest and can be used to predict possible changes of market direction. Several blue bars in a row can indicate that the market is really going sideways and a breakout may happen soon.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 |
H1 = High[0]//High L1 = Low[0]//Low C = Close[0]//Close HH1 = High[1]//High LL1 = Low[1]//Low CC = Close[1]//Close Pivot1 = (HH1 + LL1 + CC) / 3 R11 = 2*((HH1 + LL1 + CC) / 3)- LL1 S11 = 2*((HH1 + LL1 + CC) / 3)- HH1 Pivot = (H1 + L1 + C) / 3 R1 = 2*((H1 + L1 + C) / 3)- L1 S1 = 2*((H1 + L1 + C) / 3)- H1 //Outside Pivot Up IF R1 > R11 and S1 < S11 and Pivot > Pivot1 THEN//R1 - R11 > S11 - S1 THEN Flagup = 3 FlagDown = -2 R = 0 G = 0 B = 255 ENDIF //Outside Pivot Down IF R1 > R11 and S1 < S11 and Pivot < Pivot1 THEN//R1 - R11 < S11 - S1 THEN Flagup = 2 FlagDown = -3 R = 0 G = 0 B = 255 ENDIF //Inside Pivot Up IF R1 < R11 and S1 > S11 and Pivot > Pivot1 THEN//R11 - R1 < S1 - S11 THEN FlagUp = 1.5 FlagDown = 0.5 R = 0 G = 0 B = 255 ENDIF //Inside Pivot Down IF R1 < R11 and S1 > S11 and Pivot < Pivot1 THEN//R11 - R1 > S1 - S11 THEN FlagUp = -0.5 FlagDown = -1.5 R = 0 G = 0 B = 255 ENDIF //Up Pivot IF R1 > R11 and S1 > S11 THEN Flagup = 2 FlagDown = -2 R = 0 G = 255 B = 0 ENDIF //Down Pivot IF R1 < R11 and S1 < S11 THEN Flagup = 2 FlagDown = -2 R = 255 G = 0 B = 0 ENDIF return FlagUp coloured(R,G,B) Style(Histogram,2) as "Pivot Analysis",FlagDown coloured(R,G,B) Style(Histogram,2) as "Pivot Analysis" |
Share this
No information on this site is investment advice or a solicitation to buy or sell any financial instrument. Past performance is not indicative of future results. Trading may expose you to risk of loss greater than your deposits and is only suitable for experienced investors who have sufficient financial means to bear such risk.
ProRealTime ITF files and other attachments :PRC is also on YouTube, subscribe to our channel for exclusive content and tutorials
Sorry – there is a cut and paste mistake in the above description. It should read:
A green bar indicates that this is a bullish candle.
A red bar indicates that this is a bearish candle.
A long blue bar indicates that this candle was a more volatile candle.
A short blue bar indicates that this candle was a candle of indecision.
The indicator bar below each candle refers to the sentiment of the candle immediately above it.
I made the change accordingly. Thank you for that indicator.
Thank you for this indicator Vonasi
Ca cogite sévère !!! 🙂
Bravo
Cpdt je n’ai pas compris “La barre indicatrice sous chaque bougie fait référence au sentiment de la bougie immédiatement au-dessus.”???
Google Traduction! Contrairement aux lignes de pivot quotidiennes qui montrent aujourd’hui ce qui s’est passé hier, cet indicateur montre ce qui se passe dans cette bougie par rapport à la dernière bougie.
You got me infected, thinking about pivoting my morning coffee 🙂
Sorry I did not see you were on the other side of the sleeve 🙂
Pas de problème. C’est juste quelque chose que je dois vivre avec!
Thank you for the indicator Vonasi. Very useful for manual trading.
The indicator code can easily be adapted for use as a filter in strategies as well. For example if the last three bars are blue then set stops and limits for a potential breakout. Just one idea.
Tested today in manual DAX trading (transcripted to MT and changed look into aka oszillator). Results: too noisy in M1, M5 better; seems there’s a limit around 4 greens/reds before we get a blue. Seems to work good to get the highs/lows of default macd histogram.
I think that short time frame charts will be too noisy for this indicator. One blue bar really only indicates a slight hesitation in the market and on short time frames there will be an awful lot of hesitations. A longer time frame and looking out for periods with several blues in a row gives a better idea of whether the market has truly entered a period of indecision. Not tested but just based on my humble opinion.