OPEN-SOURCE SCRIPT

Pivot Trend Flow [BigBeluga]

2 020
🔵 OVERVIEW
Pivot Trend Flow [BigBeluga] turns raw swing points into a clean, adaptive trend band. It averages recent pivot highs and lows to form two dynamic reference levels; when price crosses above the averaged highs, trend flips bullish and a green band is drawn; when it crosses below the averaged lows, trend flips bearish and a red band is drawn. During an uptrend the script highlights breakouts of previous pivot highs with ▲ labels, and during a downtrend it flags breakdowns of previous pivot lows with ▼ labels—making structure shifts and continuation signals obvious.

🔵 CONCEPTS
  • Pivot-Based Averages: Recent pivot highs/lows are collected and averaged to create smoothed upper/lower reference levels.
    Pine Script®
    if not na(ph) phArray.push(ph) if not na(pl) plArray.push(pl) if phArray.size() > avgWindow upper := phArray.avg() phArray.shift() if plArray.size() > avgWindow lower := plArray.avg() plArray.shift()
    Snapshot
  • Trend State via Crosses: Close above the averaged-highs ⇒ bullish trend; close below the averaged-lows ⇒ bearish trend.
  • Trend Band: A colored band (green/red) is plotted and optionally filled to visualize the active regime around price.
    Snapshot
  • Structure Triggers:
    In bull mode the tool watches for prior pivot-high breakouts (▲).
    Snapshot
    In bear mode it watches for prior pivot-low breakdowns (▼).
    Snapshot


🔵 FEATURES
  • Adaptive Trend Detection from averaged pivot highs/lows.
  • Clear Visuals: Green band in uptrends, red band in downtrends; optional fill for quick read.
  • Breakout/Breakdown Labels:
    ▲ marks breaks of previous pivot highs in uptrends
    ▼ marks breaks of previous pivot lows in downtrends
  • Minimal Clutter: Uses compact lines and labels that extend only on confirmation.
  • Customizable Colors & Fill for trend states and band styling.


🔵 HOW TO USE
  • Pivot Length: Sets how swing points are detected. Smaller = more reactive; larger = smoother.
  • Avg Window (pivots): How many recent pivot highs/lows are averaged. Increase to stabilize the band; decrease for agility.
  • Read the Band:
    Green band active ⇒ prioritize longs, pullback buys toward the band.
    Red band active ⇒ prioritize shorts, pullback sells toward the band.
  • Trade the Triggers:
    In bull mode, ▲ on a prior pivot-high break can confirm continuation.
    In bear mode, ▼ on a prior pivot-low break can confirm continuation.
  • Combine with Context: Use HTF trend, S/R, or volume for confluence and to filter signals.
  • Fill Color Toggle: Enable/disable band fill to match your chart style.


🔵 CONCLUSION
Pivot Trend Flow [BigBeluga] converts swing structure into an actionable, low-lag trend framework. By blending averaged pivots with clean breakout/breakdown labels, it clarifies trend direction, timing, and continuation spots—ideal as a core bias tool or a confirmation layer in any trading system.

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.