Aura Pivot S/R Matrix [Pineify]Aura Pivot S/R Matrix
This indicator turns confirmed swing pivots into volatility-adaptive support and resistance zones rather than single horizontal lines. The thickness of each zone is derived from a 200-bar ATR snapshot taken at the pivot bar itself — so a level formed during a quiet consolidation gets a narrower zone than one formed during a wide-range expansion, without any manual tuning per instrument. Each zone tracks forward with price until a full close breaks through it, at which point the zone is frozen and labeled as a breakout or breakdown.
Key Features
ATR-scaled zone thickness anchored to the volatility regime at the pivot bar, not the current bar
Forward-extending zones that visually "track" price until broken, then freeze as a historical record
Close-based break detection that filters out wick probes and test-and-reject candles
Per-zone state management via a user-defined type — each zone behaves as an independent object with its own lifecycle
Breakout and breakdown labels printed at the exact bar of confirmation
How It Works
Each zone is built through a three-stage pipeline — pivot confirmation, volatility-scaled construction, and lifecycle tracking.
A swing is detected when a bar's high is higher than the surrounding pivotLen bars on both sides (for resistance), or the low is lower (for support). Because the right-side requires N bars of confirmation, zones appear with a deterministic pivotLen -bar lag and do not repaint once drawn
At the moment a pivot confirms, the script measures the 200-bar ATR as it existed pivotLen bars ago — that is the volatility context at the actual swing bar, not the current bar. The zone is then drawn as a box extending ±(ATR/2) around the pivot price
Each zone is stored in an SRZone user-defined type that bundles its box, midline, label, pivot level, and a boolean broken flag. Two arrays — one for resistance, one for support — hold the active inventory
On every bar, unbroken zones have their right edge extended forward. When the close exceeds the top of a resistance zone (or falls below the bottom of a support zone), the zone stops extending, is marked broken, and a labeled marker is drawn at the break bar
How the Components Work Together
Three design decisions interact to produce the final behavior.
The pivot detection answers where market structure previously turned — these are locations where orders likely clustered and will likely cluster again on retest. The ATR scaling answers how wide the reaction range around that pivot should be, because a pivot formed during a low-volatility session does not represent the same defensive range as one formed during a volatile expansion. Combining the two produces zones that are structurally anchored but volatility-proportional.
The close-based break filter then handles the noise problem. The most common false break is a wick that tags the level, prints a panic candle, and reverses immediately. By requiring a full close beyond the zone, the indicator rewards conviction moves and ignores exploratory probes — the break is registered only when price has committed to the new regime.
Trading Ideas and Insights
Repeated tests of a fresh resistance zone without a closing break frequently precede a sustained reversal. The more times a zone is defended, the more meaningful the eventual breakout becomes
When a resistance zone breaks and then holds as support on retest, that flip is a classic structural shift — an opportunity to align with the new direction using the flipped zone as a clear invalidation level
Support zones broken during strong trending conditions rarely hold on retest. Support broken during ranging conditions often reforms because the market was simply oscillating — context from the broader trend matters
A cluster of multiple pivots at similar prices (three or four zones stacking) marks a confluence area that carries more weight than an isolated swing
Past behavior at these levels does not guarantee future reactions. Treat zones as bias filters rather than standalone signal generators.
Unique Aspects
Most S/R indicators use fixed-distance zones, round numbers, or percentage bands. This one scales zone thickness to a rolling ATR measured at the exact bar of the pivot — so a 2020 level and a 2024 level on the same chart can have very different zone widths depending on the volatility regime that produced them
Zones freeze on break rather than being deleted, preserving a visual history of which structural levels have been tested and lost. This acts as a passive context map for traders reading price action
State is managed through a UDT array rather than a flat set of lines, which makes the extend-until-broken behavior clean and predictable — each zone owns its own break detection logic
How to Use
Add the indicator to any chart and timeframe you actively trade. 1H and 4H are good starting points for swing traders; lower timeframes work but will produce more zones and benefit from a higher pivot lookback value
Identify the nearest active support zone (green) and resistance zone (red) — these are the first levels price is likely to react to
Watch for one of two outcomes: a controlled approach followed by rejection (fade setup), or a decisive close through the zone (breakout setup). The indicator labels the breakout or breakdown automatically
When a level breaks, expect a retest. Retests often offer better reward-to-risk entries than chasing the initial breakout bar itself
Customization
Pivot Lookback Length (default: 15) — Bars required on each side of a swing for confirmation. Lower values (5-10) produce smaller, more frequent zones suitable for scalping. Higher values (20-30) isolate only major structural swings and reduce chart clutter
Zone Width (ATR Multiplier) (default: 1.0) — Scales the ATR-derived zone thickness. Raise to 1.5-2.0 on volatile instruments where zones should absorb normal noise; lower to 0.5 for tighter precision-entry levels
Support / Resistance Color — Visual differentiation between bullish and bearish zones, their midlines, and labels
Zone Transparency (default: 85) — Controls the fill opacity of zone boxes. Values around 80-90 keep price action readable inside the zone
Limitations to Be Aware Of
The pivot confirmation delay equals the lookback length. A 15-bar lookback means the zone is drawn 15 bars after the actual swing high or low. This is fine for levels (they do not repaint) but unsuitable for entries at the exact swing bar
Zones do not automatically merge. When multiple pivots form within an ATR of each other, their zones will overlap on the chart. Increasing the pivot lookback reduces this visual clutter
Break detection uses close , not wicks. A bar can spike well beyond the zone and return inside without triggering a break — by design, but worth remembering on volatile instruments with large intrabar swings
Conclusion
Rather than plotting dozens of static lines, the Aura Pivot S/R Matrix treats each structural pivot as a live object with a volatility-scaled range and a clear lifecycle — active, then broken. The ATR scaling grounds each zone in the volatility context of its own formation, and the close-based break detection emphasizes conviction moves over noise. Most useful as a structural framework for swing and position traders who want to see where the market has been defended, where those defenses have been lost, and how the battleground has evolved across different volatility regimes.
Penunjuk Pine Script®






















