Divergence/Convergence v1.0
Dec 25, 2018

The Divergence/Convergence v1.0 indicator identifies potential trend reversals by monitoring multiple technical indicators simultaneously for bullish convergence and bearish divergence signals.
Usage
The indicator displays arrows on the chart to signal potential reversals. Unlike standard divergence tools that focus on a single oscillator, this script aggregates signals from several sources. The strength or confidence of a signal is visualized through the length of the arrows:
- An arrow length of 1 indicates a divergence/convergence detected on a single underlying indicator.
- An arrow length of 2 or more indicates that multiple indicators are showing the same signal simultaneously, suggesting a higher probability setup.
Users can look for these multi-indicator signals to confirm potential price exhaustion or trend shifts. Green arrows pointing upwards represent bullish convergence (price making lower lows while indicators make higher lows), and red arrows pointing downwards represent bearish divergence (price making higher highs while indicators make lower highs).
Details
The script evaluates the following technical indicators to find signals:
- Relative Strength Index (RSI): Measures the speed and change of price movements.
- MACD Line: Tracks the relationship between two moving averages of a security’s price.
- MACD Histogram: Measures the distance between the MACD and its signal line.
- Momentum: Measures the rate of the rise or fall in stock prices.
- Chaikin Money Flow (CMF): Measures the amount of Money Flow Volume over a specific period.
The detection logic iterates through a user-defined lookback window (default 25 bars) to find discrepancies between price peaks/troughs and indicator peaks/troughs.
Settings
- Number of Bars to look back: Sets the window size (between 10 and 50 bars) used to search for historical peaks and troughs to compare against current price action.
FAQ
How do I interpret the different arrow sizes?
The size of the arrow corresponds to the number of underlying indicators currently signaling a divergence or convergence. A larger arrow means more indicators (RSI, MACD, etc.) are in agreement.
Can I change which indicators are used?
The current version pre-calculates RSI, MACD, Momentum, and CMF. While the core logic is set, the lookback period can be adjusted to change how sensitive the detection is to historical price points.
How can I access Divergence/Convergence v1.0?
You can get access on the LuxAlgo Library for charting platforms like TradingView, MetaTrader (MT4/MT5), and NinjaTrader for free.
Free indicator
Get free access to this indicator on the platforms below.
Unlock the entire LuxAlgo Library
Every indicator, every strategy, full charts, and complete access to Quant — our AI agent.