PROTECTED SOURCE SCRIPT

Fractals by KaraTrade

33
Fractals by KaraTrade

OVERVIEW
This indicator identifies fractal patterns on the chart, which are key reversal points in price action. Fractals help traders identify potential support and resistance levels, as well as trend reversal zones.

WHAT IS A FRACTAL?
A fractal is a pattern where a central candle's high or low is surrounded by lower highs or higher lows on both sides. Fractals indicate where the market has made a local extreme and potentially reversed direction.

FEATURES

5-Candle Fractals (Dark Gray X marks)
  • Stronger signals with strict pattern validation
  • Requires a clear sequence where each candle progressively moves toward the center and then away
  • Bearish fractal: high[4] < high[3] < high[2] > high[1] > high[0]
  • Bullish fractal: low[4] > low[3] > low[2] < low[1] < low[0]
  • The central candle [2] must be the highest high (bearish) or lowest low (bullish)
  • Displayed with offset=-2 on the central candle


3-Candle Fractals (Light Gray Triangles)
  • Weaker signals for more frequent patterns
  • Simpler pattern: central candle must be higher or lower than both neighbors
  • Bearish fractal: high[2] < high[1] > high[0]
  • Bullish fractal: low[2] > low[1] < low[0]
  • Displayed with offset=-1 on the central candle


SETTINGS
  • Show 5-Candle Fractals: Toggle 5-candle fractal display
  • Show 3-Candle Fractals: Toggle 3-candle fractal display


HOW TO USE
  • Bearish Fractals (top): Potential resistance levels or sell zones
  • Bullish Fractals (bottom): Potential support levels or buy zones
  • Use in combination with other indicators for confirmation
  • 5-candle fractals are more reliable but less frequent
  • 3-candle fractals provide more signals but require additional confirmation


TECHNICAL DETAILS
  • Uses strict sequential logic (no equal values allowed)
  • Based on high/low prices (including wicks/shadows)
  • Displays with a delay for pattern confirmation
  • Compatible with all timeframes


Created by KaraTrade

Disclaimer

The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.