RSI
Feb 1, 2021

The RSI indicator tool is an advanced momentum oscillator based on John Hayden's "RSI: The Complete Guide," designed to identify trend regimes, momentum shifts, and market extremes through specific threshold analysis. It provides traders with a comprehensive view of market strength by categorizing price action into distinct uptrend and downtrend zones based on relative strength values.
Usage
The RSI tool can be used to identify trend direction and potential reversal points through the following interpretations:
- Uptrend Identification: A market is considered in an uptrend when RSI values consistently remain within the 80/40 range. During these periods, hidden bullish divergences often suggest trend continuation.
- Downtrend Identification: A market is considered in a downtrend when RSI values remain within the 60/20 range. Bullish divergences in this zone may indicate a retracement before further downside.
- Momentum Thresholds: The indicator highlights 2:1 momentum (66.67/33.33 levels) as key support and resistance. Breaks of these levels signal shifts in market dominance.
- Divergence Analysis: Simple and hidden divergences are plotted to show where momentum is decoupling from price, indicating potential exhaustion or upcoming trend resumption.
- Trendline Breaks: The script includes diagonal trendline breaks on the RSI itself, changing the line color to signal momentum breakouts.
Details
This script implements concepts from John Hayden's momentum theory, specifically the idea that RSI ranges shift based on the prevailing trend. Unlike standard RSI interpretations that focus solely on 70/30 levels, this tool uses 80/40 and 60/20 boundaries to define "Trend States."
Additional logic has been added for horizontal pivot breaks and diagonal trendline breaks. The 80/20 lines change color based on horizontal pivot breaches, while the RSI line itself reacts to diagonal trendline violations. The 66.67 and 33.33 levels act as mathematical "2:1 momentum" markers, serving as dynamic support or resistance depending on the current trend state.
Settings
RSI Settings
- RSI Length: Determines the lookback period for the RSI calculation.
- Show Trend State: Toggles the background coloring based on the current trend regime.
- Show Trend Momentum (2:1 / 3:1): Displays highlight zones for specific momentum ratios.
- Show OB/OS: Toggles the visibility of 4:1 momentum (80/20) extreme market condition highlights.
Visuals & Pivots
- Show Diag Breaks: Enables color changes on the RSI line when diagonal trendlines are broken.
- Show Horizontal Pivot Initial Break: Highlights when the RSI crosses the most recent horizontal pivot point.
- Show Pivot Points: Displays circles at identified high and low pivot points.
- Pivot Length (Left/Right): Adjusts the required bars on either side to confirm a pivot.
Divergence Settings
- Pivot Lookback (Left/Right): Defines the window for identifying divergence peaks/troughs.
- Max/Min Lookback Range: Sets the distance constraints for finding two points of divergence.
- Plot Bullish/Bearish/Hidden: Toggles the display of specific divergence types.
FAQ
How do I interpret the RSI color changes? The RSI line changes color based on diagonal trendline breaks, while the background and boundary lines change color based on the overall trend state (Uptrend vs. Downtrend).
What do the 66.67 and 33.33 levels represent? These represent 2:1 momentum ratios. In a strong trend, these levels often act as the first line of support or resistance for the oscillator.
How can 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.