Divergence of Market Breadth & Price deduction indicator

Oct 14, 2020

Static chart image
Signals
Divergences
Moving Averages

The Divergence of Market Breadth & Price deduction indicator tool provides a multi-faceted approach to analyzing market health and trend strength by comparing internal market breadth data and price-to-moving-average relationships. It aims to offer traders early warning signs of price reversals or trend exhaustion by identifying divergences between major indices and price-specific metrics.

Usage

The script offers three distinct operating modes that can be selected from the "Options" setting:

  1. Market Breadth Divergence (MB): Compares the percentage of stocks above their 20-period Simple Moving Average (SMA) for the Nasdaq 100 (NDTW) and the Russell 2000 (R2TW). This mode highlights the relative strength between tech-heavy and small-cap stocks, serving as a barometer for broad market participation.
  2. Price Divergence (PDI): Measures the distance between the current price and various Exponential Moving Averages (20, 60, and 120). This helps identify when a trend is overextended or losing momentum.
  3. Price Deduction (PDE): Uses a deduction method inspired by LEI and LoneCapital to calculate the percentage change of price relative to its historical values at 20, 60, and 120-bar offsets, providing a view of momentum and trend structure.

Details

The indicator relies on the concept that healthy market rallies are usually supported by broad participation (market breadth). When the Nasdaq 100 outpaces small-caps significantly, or when the price moves too far away from its long-term averages, a divergence occurs.

  • Market Breadth: Uses the ratio of (NDTW / R2TW) - 1 to find leadership shifts.
  • Price Divergence/Deduction: Uses normalized values to allow for comparison across different assets, looking at Short/Mid/Long-term relationships.
  • Smoothing: All modes include Hull Moving Averages (HMA) to smooth the data and provide clearer crossover signals for trend changes.

Settings

General Settings

  • Options: Selects the active mode (Market Breadth Divergence, Price Divergence, or Price Deduction).

Market Breadth Divergence

  • FAST MA Length: The period for the fast smoothing line (HMA).
  • SLOW MA Length: The period for the slow smoothing line (HMA).
  • Long term MA Length: The period for the long-term baseline.

Price Divergence

  • FAST MA Length: The period for the fast smoothing line applied to the Close/Short divergence.
  • SLOW MA Length: The period for the slow smoothing line.

Price Deduction

  • Price Deduction MA Length: The period for the smoothing lines applied to the 20, 60, and 120-period deduction lines.

FAQ

How do I access the Divergence of Market Breadth & Price deduction indicator?

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

What indices are used for market breadth?

The script specifically requests data for the Nasdaq 100 (NDTW) and Russell 2000 (R2TW) percentage of stocks above their 20 SMA.

Can I set alerts for crossovers?

Yes, the script includes built-in alert conditions for HMA crossovers within each of the three modes.

Free access on the following platforms
tradingviewSymbolTradingView
Open in your browser

This in-app browser is not compatible with Get Access from the library.

Tap the menu (...) at the top of your screen and select "Open in Browser", "Open in Safari", or "Open in Chrome" to continue.

ninjatraderNinjaTrader
Open in your browser

This in-app browser is not compatible with Get Access from the library.

Tap the menu (...) at the top of your screen and select "Open in Browser", "Open in Safari", or "Open in Chrome" to continue.

metatrader4MetaTrader 4/5
Open in your browser

This in-app browser is not compatible with Get Access from the library.

Tap the menu (...) at the top of your screen and select "Open in Browser", "Open in Safari", or "Open in Chrome" to continue.

thinkorswimThinkorswim
Open in your browser

This in-app browser is not compatible with Get Access from the library.

Tap the menu (...) at the top of your screen and select "Open in Browser", "Open in Safari", or "Open in Chrome" to continue.

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.