Rolling Segment

Draws volatility-adjusted trend line segments that automatically pivot when market conditions change. Coloured green during uptrends and red during downtrends, with pivot points clearly marked.

Dynamic OverlaysPrice ActionFree
TradingViewMetaTrader 5

About This Indicator

The Rolling Segment indicator continuously draws a series of connected trend line segments that adapt to current market volatility. Each segment represents a distinct directional phase green for bullish momentum, red for bearish and pivots automatically when the price structure shifts.

The pivot points are calculated using ATR-adjusted swing detection, ensuring the indicator responds to meaningful structural changes rather than minor noise. This makes it effective for identifying trend reversals and continuation patterns across all asset classes.

Key Features

  • Automatic trend phase detection with colour-coded segments
  • ATR-based pivot sensitivity adapts to volatility, not fixed thresholds
  • Clearly marked pivot dots at each structural change point
  • Works on TradingView (Pine Script v5) and MetaTrader 5 (MQL5)
  • Alert on segment pivot bullish or bearish flip
  • No repainting after bar close

How to Use

  • Enter long when a green segment starts after a confirmed pivot from red
  • Enter short when a red segment starts after a confirmed pivot from green
  • Place stops just beyond the pivot point that triggered the entry
  • Best used on 1H–Daily timeframes; avoid lower timeframes in low-volatility sessions
  • Combine with order block or FVG confluence for higher-probability setups