MACD Hist Divergence

Price/Oscillator Divergence Detector.

This detects the following divergences between price and the oscillator.
  • Regular Bullish Divergence: Price lower low | Oscillator higher low
  • Regular Bearish Divergence: Price higher high | Oscillator lower high
  • Hidden Bullish Divergence: Price higher low | Oscillator lower low
  • Hidden Bearish Divergence: Price lower high | Oscillator higher high

Settings and Options.

  • Lookback windows to identify pivot points .
  • -The signal will be delayed by the number of bars used in the right lookback window.
  • Maximum range to detect divergence is the largest distance allowed between two pivots for them to be considered.
  • Option to plot hidden and regular divergences.
  • Option to use the price bars or oscillator to detect pivot points . If using price, the source used to calculate the oscillator (default is close) or high/low can be used.
  • Require histogram to cross 0 line between pivots for valid divergence

MACD Histogram
  • Price source.
  • Fast MA length
  • Slow MA length
  • Signal Length

Note: Click the settings cog next to the indicator name to access all the settings after addition of the indicator to the chart.

Links to my other indicators
TD sequential indicator

RSI Divergences

OBV Oscillator Divergences

TD alternatives

RSI with a horizontal line

Plot MAs

Average directional index with directional movement indicator

Market Hours

Referral Links
Bitmex 10% fee discount for 6 months
TradingView (50% off after trial period ends)

Tip Jar
LTC: LM9KsXz7GUxCN9g9EjTC8ayviDEmBK14rw

Release Notes: An asterisk will appear next to a divergence if it meets the criteria below (as recommended by Kerry Lovvorn's research).
  • The distance between pivots of the histogram is between 20 to 40 bars (and less than the user input limit)
  • The histogram crosses 0 between the two pivots
  • The second peak/trough is less than half the size of the first.
Release Notes: You can now specify lower and upper values of lookback range for divergence consideration.
Remove from Favorite Scripts Add to Favorite Scripts
May I have access to this one too? Thank you!
Please could I have access to the MACD & RSI divergence indicator please they look very good and I would like to test them out many thanks in advance.

Would you please allow me to use your MACD & RSI Divergence ? God bless you :D
HI can i try this indicator. Thanks
Hi jdlim, Can I have access to the script, please?
Hi jdlim, Can I have access to the script, please?

Thanks in advance for your support!
Hi jdlim! can i get access to your script? It looks very promising
Great work, jdlim. Very interested in your MACD and RSI indicators. Can I use the script? Thanks a lot.
+1 Reply
Hello jdlim, would like to use the script. Kindly grant access.
+1 Reply
Hi @jdlim, indi looks great! May I please have access to it? Cheers!
Home Stock Screener Forex Screener Crypto Screener Economic Calendar How It Works Chart Features Pricing House Rules Moderators Website & Broker Solutions Widgets Charting Solutions Get Help Feature Request Blog & News FAQ Wiki Twitter
Profile Profile Settings Account and Billing Get Help Ideas Published Followers Following Private Messages Chat Sign Out