Delta-RSI Oscillator Strategy
Jan 30, 2021

The Delta-RSI Oscillator Strategy indicator provides a momentum-based trading framework by calculating a smoothed time derivative of the RSI using polynomial regression. It identifies shifts in momentum and trend direction by transforming the standard RSI into an oscillatory histogram that tracks velocity rather than raw value.
Usage
The Usage section describes how the script can be used to identify potential entry and exit points based on momentum shifts. The indicator calculates the rate of change of the RSI curve to provide earlier indications of trend exhaustion or reversal compared to standard RSI levels.
Signal Generation
The script provides three distinct methods for generating buy, sell, and exit signals:
- Zero-crossing: A bullish signal is generated when the Delta-RSI crosses above zero (positive momentum), and a bearish signal occurs when it crosses below zero (negative momentum).
- Signal Line Crossing: Uses an EMA of the Delta-RSI as a trigger. A bullish signal occurs when the histogram crosses above the signal line.
- Direction Change: Identifies inflection points. A bullish signal is triggered when the Delta-RSI is negative but begins to rise, while a bearish signal is triggered when it is positive and begins to fall.
Error Filtering
Because the tool relies on local polynomial interpolation, users can enable an RMSE (Root-Mean-Square Error) filter. This prevents signals from triggering during periods where the RSI price action is too erratic for a reliable mathematical fit, ensuring signals only occur when the model accurately represents the underlying data.
Details
The script is built upon the concept of local regression. Instead of calculating a simple difference, it applies a polynomial function to a window of RSI data points. The derivative of this fitted polynomial represents the "Delta" (velocity) of the RSI.
Key technical components include:
- Polynomial Fitting: Uses a user-defined order to interpolate the RSI curve.
- Matrix Operations: Employs QR decomposition and pseudo-inverse calculations to solve the regression model within the Pine Script environment.
- Smoothing: The resulting velocity is smoothed, providing a histogram that oscillates around a zero center-line, making it easier to visualize bullish and bearish momentum cycles.
Settings
Model Parameters
- Polynomial Order: Determines the complexity of the local polynomial function used to interpolate the RSI.
- RSI Length: The period used to calculate the base RSI input.
- Length ( > Order): The lookback window size used for the local regression calculation.
- Signal Length: The period for the EMA applied to the Delta-RSI to create the signal line.
Show Signals
- Buy: Toggles the visibility of bullish entry labels.
- Sell: Toggles the visibility of bearish entry labels.
- Exit: Toggles the visibility of exit markers (represented as crosses).
Entry and Exit Conditions
- Buy/Sell/Exit Dropdowns: Allows the user to select between Zero-Crossing, Signal Line Crossing, or Direction Change for each specific signal type.
RSI Fitting Error Filter
- Filter by Means of Root-Mean-Square Error: Enables or disables the RMSE filter.
- RSI Fitting Error Threshold, %: Sets the sensitivity of the filter; higher values allow more signals, while lower values restrict signals to high-confidence fits.
FAQ
How do I interpret the histogram?
The histogram represents the speed of the RSI. When the histogram is above zero, RSI momentum is increasing; when below zero, it is decreasing. Extremes in the histogram can indicate overextended momentum.
What is the advantage of using Direction Change signals?
Direction Change signals aim to catch reversals earlier than zero-crossings by identifying the moment the RSI velocity stops decreasing (while still negative) or stops increasing (while still positive).
How do I access this tool?
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.