OPEN-SOURCE SCRIPT

Swing High-Low Line Connector

93
Swing High-Low Line Connector is a simple and intuitive tool that automatically detects swing highs and swing lows using fractal-style pivot logic and connects them with clean, continuous lines. This indicator helps traders visualize market structure, trend shifts, and swing-based support/resistance levels at a glance.

The script identifies each confirmed swing point based on a user-defined lookback window (left/right bars). When a new swing is confirmed, the indicator updates the previous leg or creates a new one, effectively drawing the classic “zigzag-style” connections used in discretionary trading and price-action analysis.

A dynamic tail extension is included to show the most recent swing extending toward the current price. By default, the tail follows a ZigZag-style logic—extending upward after a swing low and downward after a swing high—but users can also anchor it to Close, High, Low, or HL2.

Features
  • Automatic detection of swing highs and swing lows
  • Clean line connections between swings (similar to discretionary market-structure mapping)
  • Proper consolidation handling: weaker highs/lows are ignored
  • Optional ZigZag-style dynamic tail extension
  • Fully customizable lookback window, line color, and line width
  • Works on any market and timeframe


Use Cases
  • Identifying market structure (HH, HL, LH, LL)
  • Visualizing trend transitions
  • Spotting breakout levels and swing-based support/resistance
  • Aiding discretionary swing trading, trend following, or pattern recognition


This indicator keeps the logic simple and visual—ideal for traders who prefer clean chart structure without unnecessary noise.

Haftungsausschluss

Die Informationen und Veröffentlichungen sind nicht als Finanz-, Anlage-, Handels- oder andere Arten von Ratschlägen oder Empfehlungen gedacht, die von TradingView bereitgestellt oder gebilligt werden, und stellen diese nicht dar. Lesen Sie mehr in den Nutzungsbedingungen.