Trading ABC

Sep 3, 2021

Static chart image
Price Action Based
Support and Resistance
Signals
Fibonacci
Moving Averages
Patterns

The Trading ABC indicator identifies and plots ABC correction patterns based on price action and trend confirmation to find potential trend continuation opportunities. It combines multiple moving averages, ZigZag logic, and Fibonacci retracement levels to filter and validate these classic chart patterns.

Usage

The Usage section describes how the script can be used to identify trend-aligned pullbacks. The tool is designed to highlight specific "ABC" structures where price moves against the dominant trend before resuming its original direction.

  • Trend Filtering: The indicator uses a "Trend Cloud" composed of six moving averages (four SMAs and two EMAs). Signals are only generated when the price action is supported by the trend; for example, a bullish ABC pattern is only valid during an uptrend.
  • Pattern Validation: The script uses a ZigZag algorithm to identify local highs and lows. It then calculates the ratio of the current wave against the previous wave. If this ratio falls within the user-defined Fibonacci Min and Max range (e.g., 0.382 to 0.618) and adheres to a specified error rate, an ABC pattern is identified.
  • Entry Signals: Triangles appear on the chart when an ABC pattern is confirmed and price "bounces" off the Trend Cloud. A bounce is defined by price interacting with one of the moving averages and closing in the direction of the trend. Multiple triangles may appear if the price bounces several times following the pattern formation.

Details

The script executes a multi-step logic to ensure signal quality:

  1. Trend Cloud Construction: It calculates SMAs (50, 100, 150, 200) and EMAs (20, 40). A bullish trend is confirmed if moving averages are below the price, while a bearish trend is confirmed if they are above.
  2. ZigZag & Fibonacci: The script tracks the last two ZigZag waves. It calculates the retracement level of point C relative to the A-B move.
  3. Error Rate: The "Error Rate" setting adds a buffer to the Fibonacci levels, allowing for slight deviations in market precision while still recognizing the core pattern.
  4. Bouncing Logic: To avoid premature entries, the script checks for a candle bounce (price crossing and closing above/below an MA) within 6 bars of the pattern completion.

Settings

Setup

  • ZigZag Period: Determines the sensitivity of the peak and trough detection. Higher values result in larger, more significant waves.
  • Fibonacci Max: The maximum allowable retracement level for the C point (default 0.618).
  • Fibonacci Min: The minimum allowable retracement level for the C point (default 0.382).
  • Error Rate: The percentage of deviation allowed from the Fibonacci levels (e.g., a 5% error rate expands the valid range slightly).

Extras

  • Show ABC: Toggles the visibility of the ABC labels and connecting lines.
  • Keep Old ABCs: If enabled, historical ABC patterns remain on the chart. If disabled, only the most recent pattern is shown.
  • Show Cloud: Toggles the visibility of the Trend Cloud.
  • Show Zig Zag & Fibo: Displays the underlying ZigZag lines and the active Fibonacci retracement zone for the current wave.

Trend Cloud

  • Source for Moving Averages: The price source used for MA calculations (default is Close).
  • SMA/EMA Lengths: Individual inputs to customize the periods of the six moving averages used to determine the trend and bounce zones.

FAQ

How do I interpret the triangles on the chart? A triangle pointing up indicates a bullish ABC pattern has completed and the price has successfully bounced off the trend support, suggesting a potential long entry. A downward triangle indicates a bearish ABC pattern with a rejection from trend resistance.

Why does an ABC pattern sometimes appear without a triangle? The ABC pattern label indicates the geometric structure is present, but a triangle only appears if the price also satisfies the "bounce" condition against the moving averages and occurs within the trend direction.

How can I access the Trading ABC indicator? 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.