Skip to content
All library documents

Pivot Trendline Breakouts with ATR-Based Exit Levels

Article ProRealCode

Summary

This indicator identifies swing pivots using a configurable left and right bar window, with pivots based either on candle wicks or bodies. It connects descending pivot highs and ascending pivot lows, projects those lines forward, and signals a bullish break above a high-based line or a bearish break below a low-based line when the close crosses it. The pivot period and pivot source affect sensitivity and the structures detected.

At a breakout, the indicator places take-profit and stop-loss levels using a volatility buffer derived from ATR and price, then checks subsequent bars to see which level is touched first. It draws the trendline, breakout marker, exit rails, and first-exit marker. This is a charting and trade-path illustration, not evidence of a profitable strategy: the document gives no backtest results or broader execution assumptions. Its win/loss labels depend on the simulated order of price touches, and the stated defaults and multiplier are implementation choices rather than validated settings.

Key ideas

  • Swing pivots are confirmed using surrounding bars, with wick and candle-body definitions available.
  • The indicator projects lines between descending pivot highs and ascending pivot lows.
  • A close crossing the projected line triggers a directional breakout signal.
  • ATR-derived buffers define target and stop levels, and the first touched level determines the displayed outcome.
  • Pivot sensitivity and structure visibility can be adjusted through inputs.

Tags

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.