Donchian Range, RSI, and Levels System

Jan 11, 2022

Static chart image
Support and Resistance
Oscillators
Moving Averages
Volatility

The Donchian Range, RSI, and Levels System indicator provides a comprehensive visualization of market trend and support/resistance zones by utilizing a ribbon of Donchian Moving Averages combined with RSI-based coloring. It aims to identify natural price clusters where multiple Donchian lengths converge, signaling potential areas of market interest or trend exhaustion.

Usage

The indicator can be used to identify trend direction and volatility ranges. The primary component is the Donchian Ribbon, which plots multiple Donchian averages simultaneously. When these lines cluster together, they often form significant support or resistance levels.

Users can also enable the Donchian Channel to define the overall price range over a specific period. The optional "RSI Rainbow" feature provides a color-coded gradient based on the Relative Strength Index of each average, allowing traders to quickly gauge overbought or oversold conditions across various time horizons directly on the price chart.

Details

A Donchian average is calculated as the midpoint between the highest high and the lowest low for a given lookback period: (highest + lowest) / 2. By plotting 21 different lengths of these averages (ranging from 2 to 22 by default), the script creates a "ribbon" effect.

The implementation uses an RSI-based color gradient (Rainbow) that maps RSI values to a specific color array. This allows the ribbon to change color dynamically based on momentum:

  • High RSI values shift the ribbon toward the cooler end of the spectrum (e.g., cyan/blue).
  • Low RSI values shift the ribbon toward the warmer end (e.g., red/purple).
  • The "RSI Rainbow" can be applied both to the ribbon averages and the main Donchian Channel fill.

Settings

Donchian Channel

  • Donchian Channel on?: Toggles the visibility of the primary outer Donchian Channel.
  • Length: Sets the lookback period for the main Donchian Channel.
  • RSI Rainbow?: When enabled, the channel fill color is determined by the RSI of the channel's midpoint.
  • Channel Fill Transparency: Adjusts the opacity of the main channel background.

Donchian Moving Average Ribbon

  • Donchian Ribbon on?: Toggles the visibility of the 21 individual Donchian averages.
  • RSI Rainbow?: When enabled, each line in the ribbon is colored based on its own RSI value.
  • Ribbon Transparency: Controls the opacity of the ribbon lines.

Ribbon Lengths

  • Length 2 - 22: Allows for the individual adjustment of the lookback periods for each of the 21 lines in the ribbon.

FAQ

How do I interpret the clustering of lines?

When the multiple Donchian average lines converge into a tight band, it indicates a period of price consolidation or a significant level of support/resistance. A fan-out of the lines typically suggests a strong trending environment.

What does the "RSI Rainbow" indicate?

The colors represent the momentum of each specific average. Rapid color shifts can signal a change in trend strength or potential mean reversion points when the colors reach extreme ends of the gradient.

How can I access Donchian Range, RSI, and Levels System?

You can get access on the LuxAlgo Library for charting platforms like TradingView, MetaTrader (MT4/MT5), and NinjaTrader for free.

Free access on the following platforms
tradingviewSymbolTradingView
ninjatraderNinjaTrader
metatrader4MetaTrader 4/5
thinkorswimThinkorswim

Unlock Unlimited Access to the LuxAlgo Library

Upgrade your plan to get all indicators, strategies, charts, and full access to Quant, our AI agent.

Trading & investing are risky and many will lose money in connection with trading and investing activities. All content on this site is not intended to, and should not be, construed as financial advice. Decisions to buy, sell, hold or trade in securities, commodities and other investments involve risk and are best made based on the advice of qualified financial professionals. Past performance does not guarantee future results.

Hypothetical or Simulated performance results have certain limitations. Unlike an actual performance record, simulated results do not represent actual trading. Also, since the trades have not been executed, the results may have under-or-over compensated for the impact, if any, of certain market factors, including, but not limited to, lack of liquidity. Simulated trading programs in general are designed with the benefit of hindsight, and are based on historical information. No representation is being made that any account will or is likely to achieve profit or losses similar to those shown.

Testimonials appearing on this website may not be representative of other clients or customers and is not a guarantee of future performance or success.

As a provider of technical analysis tools and strategies, we do not have access to the personal trading accounts or brokerage statements of our customers. As a result, we have no reason to believe our customers perform better or worse than traders as a whole based on any content, tool, or platform feature we provide.

Charts used on this site are by TradingView in which the majority of our technical indicators are built on. TradingView® is a registered trademark of TradingView, Inc. www.TradingView.com TradingView® has no affiliation with the owner, developer, or provider of the Services described herein.

Market data is provided by CBOE, CME Group, BarChart, Massive, CoinAPI. Select U.S. equities data is provided through Massive. CBOE BZX real-time U.S. equities data is licensed from CBOE and provided through BarChart. Real-time futures data is licensed from CME Group and provided through BarChart. Select cryptocurrency data, including major coins, is provided through CoinAPI. All data is provided “as is” and should be verified independently for trading purposes.

This does not represent our full Disclaimer. Please read our full disclaimer.

© 2026 LuxAlgo Global, LLC.