Volume Delta Oscillator with Divergence
Sep 15, 2025

The Volume Delta Oscillator with Divergence indicator provides a comprehensive analysis of net buying and selling pressure by combining a smoothed volume delta oscillator with divergence detection and trend-following moving averages. This tool aims to help traders identify potential trend reversals and momentum shifts by normalizing volume delta into a percentage-based oscillator, making it applicable across various assets and timeframes.
Usage
The Usage section describes how the script can be used to interpret market dynamics. Traders can utilize the indicator in several ways:
- Momentum Analysis: When the oscillator is above the zero line, it indicates positive buying pressure (bullish momentum). Conversely, values below zero indicate selling pressure (bearish momentum).
- Reversal Signals: Look for buy triangles when the oscillator crosses above the oversold threshold. Sell triangles are generated when the oscillator crosses below the overbought threshold.
- Divergence Trading: The indicator automatically plots "Bull" and "Bear" labels when it detects a discrepancy between price action and the oscillator's pivot points. A bullish divergence occurs when price makes a lower low while the oscillator makes a higher low.
- Trend Confirmation: The integrated SMA serves as a filter. For example, a long signal from an oversold crossover is often considered stronger if the SMA is also in an oversold state or trending upward.
Details
The indicator calculates volume delta per candle as volume * (close - open) / (high - low). This data is aggregated over a user-defined "Cumulative Delta Length" and smoothed using an Exponential Moving Average (EMA) to create the Delta Oscillator. To ensure consistency, the delta is expressed as a percentage of the total volume over that period.
The divergence detection mechanism looks for pivot highs and lows within a specific range. It compares the relative peaks and troughs of price action against those of the smoothed oscillator. The moving average component uses a Simple Moving Average (SMA) of the oscillator values to provide a secondary layer of trend identification.
Settings
Oscillator Settings
- Cumulative Delta Length: The period used for aggregating volume delta data.
- Smoothing Length (EMA): The length of the EMA applied to the cumulative delta to reduce noise.
- Moving Average Length (SMA): The period for the secondary trend-following SMA.
Threshold Levels
- Overbought/Oversold Threshold: Defines the upper and lower bounds for the oscillator signals.
- MA Overbought/Oversold Threshold: Defines the bounds for the SMA visual gradients.
Divergence Settings
- Pivot Length (Left/Right): The number of bars required on either side of a point to confirm a pivot high or low.
- Enable Divergence Detection: Toggles the calculation and display of bullish/bearish divergence labels.
Signal & Style Settings
- Signal Type: Allows selection between Overbought/Oversold, Zero Line, or MA Zero Line crossover signals.
- Style Settings: Various color and transparency toggles for gradients, fills, and line plots.
FAQ
How do I interpret the divergence labels?
"Bull" labels indicate a bullish divergence (potential upward reversal), while "Bear" labels indicate a bearish divergence (potential downward reversal). These should be confirmed with price action.
Why do some signals appear with a delay?
Divergence and pivot-based signals require a "Pivot Length" (right-side) to confirm a peak or trough. A higher pivot length increases signal reliability but adds more delay to the label appearance.
How can I access Volume Delta Oscillator with Divergence?
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.