Volatility Regime Compass [JOAT]Volatility Regime Compass
Introduction
Volatility Regime Compass is an open-source volatility state classifier that continuously measures where current ATR stands relative to its own historical distribution and maps it to one of four named regimes: Compressed, Normal, Elevated, and Extreme. The classification is not binary (high or low) — it uses a rolling percentile ranking against configurable lookback windows so the regime reflects where current volatility stands within its recent history, not against a fixed absolute threshold that becomes stale as market conditions evolve.
The practical value is in strategy switching: mean-reversion techniques tend to work in compressed regimes, breakout and momentum techniques in elevated ones. Knowing which regime is active before selecting a technique reduces category errors that produce losses.
Core Concepts
1. ATR Percentile Ranking
Rather than comparing ATR to a static multiplier, the indicator ranks the current ATR value within a rolling distribution of historical ATR values. This produces a percentile score from 0 to 100 that is self-normalizing across different instruments and timeframes:
float atrHi = ta.highest(atrVal, i_rankLen)
float atrLo = ta.lowest (atrVal, i_rankLen)
float atrPct = (atrHi - atrLo) > 0 ?
(atrVal - atrLo) / (atrHi - atrLo) * 100.0 : 50.0
A reading of 80 means current ATR is in the 80th percentile of its recent range — clearly elevated. A reading of 15 means ATR is near multi-period lows — compressed.
2. Four-State Regime Classification
The percentile score maps to four regimes with configurable boundary thresholds. Defaults are: Compressed (below 25th percentile), Normal (25th to 60th), Elevated (60th to 85th), Extreme (above 85th). Crossing a regime boundary triggers a transition event labeled on the chart.
3. Multi-Band Visualization
Five ATR bands project above and below close at configurable multiples (0.5×, 1×, 1.5×, 2×, 2.5× ATR). Each band is color-coded by regime — tighter bands in compressed regimes shade cooler, wider bands in extreme regimes shade hotter using a 5-stop gradient. This gives instant visual calibration of price's relationship to current volatility structure.
4. Volatility Trend
The rate of change of ATR is computed and smoothed. Positive volatility trend (ATR rising) is labeled differently from negative trend (ATR contracting). This distinguishes a currently-elevated but contracting regime from one that is expanding — the former is more likely to produce consolidation, the latter continuation.
Features
ATR percentile ranking: Self-normalizing volatility score relative to recent history
Four volatility regimes: Compressed, Normal, Elevated, Extreme with configurable boundaries
Regime transition labels: On-chart labels at every regime change event
Five ATR expansion bands: Projected above and below close, gradient-colored by regime
Volatility trend direction: Rising vs contracting ATR tracked independently of level
Candle coloring: Candles reflect current volatility regime in real time
Regime background shading: Chart background tint corresponds to current regime
Dashboard: Current ATR, percentile, regime, trend direction, and band levels
Input Parameters
ATR Settings:
ATR Period: ATR calculation length (default: 14)
Percentile Lookback: Rolling window for ATR percentile ranking (default: 100)
Regime Thresholds:
Compressed Below: Percentile below which regime is Compressed (default: 25)
Elevated Above: Percentile above which regime is Elevated (default: 60)
Extreme Above: Percentile above which regime is Extreme (default: 85)
How to Use This Indicator
Step 1: Check the Current Regime
Read the REGIME row in the dashboard. This tells you whether to expect range-bound or trending behavior in the near term.
Step 2: Watch for Regime Transitions
A transition from Compressed to Elevated is the setup for breakout strategies. A transition from Extreme back toward Normal may signal trend exhaustion.
Step 3: Use Bands as Structural Reference
The ATR bands define statistically reasonable price excursion limits for the current volatility state. Closes beyond the 2× or 2.5× band while in a Compressed regime are structurally significant events.
Step 4: Combine with Directional Indicators
This indicator classifies volatility magnitude, not direction. Pair it with a trend or momentum tool to apply regime context to directional decisions.
Indicator Limitations
Percentile ranking depends on lookback length; very short lookbacks can produce unstable regime classifications during sudden volatility spikes
The four-state classification is a simplification; volatility is continuous and regime boundaries are heuristic
Volatility expansion does not indicate direction — it only measures magnitude of movement
Originality Statement
The combination of a self-normalizing ATR percentile ranking, a four-state regime classifier with configurable percentile boundaries, gradient-coded multi-band projection, and a simultaneous volatility trend tracker in a single Pine Script v6 publication constitutes the original contribution. Standard ATR indicators display the raw value or a fixed-multiple band without regime classification or percentile normalization.
Disclaimer
This indicator is provided for educational and informational purposes only. It is not financial advice. Volatility regime classifications are statistical summaries of historical data and do not predict future price movement. Trading involves substantial risk of loss.
-Made with passion by jackofalltrades
Indicator

Temporal Bias Architect [JOAT]Temporal Bias Architect
Introduction
Temporal Bias Architect is an open-source time-structure indicator that maps price action onto three nested cycle frameworks simultaneously: weekly, daily, and 90-minute. Each framework divides its period into four sequential phases — Accumulation (A), Manipulation (M), Distribution (D), and Continuation/Reversal (X) — derived from Daye Quarterly Theory. These phases correspond to observable behavioral patterns at each time level: accumulation of position, engineered moves against the dominant bias, distribution of that position, and the resulting continuation or reversal.
The resonance score adds a second analytical layer: when all three timeframe levels are in the same phase simultaneously, the market context is most aligned and the behavioral pattern is most likely to produce a tradeable move.
Core Concepts
1. Quarterly Theory Phase Mapping
Each trading week is divided into four days (Monday through Thursday). Each trading day is divided into four six-hour blocks. Each six-hour block is divided into four 90-minute segments. The indicator assigns each division the same four-phase labels in order (A, M, D, X), creating a fractal structure where the same behavioral sequence repeats at every time scale.
The phase for each level is derived directly from time to ensure accuracy:
int dIdx = math.min(3, hour / 6) // daily 6H phase
int qIdx = math.min(3, int((hour % 6) * 60 + minute) / 90) // 90-min phase
Each phase is rendered as a color-coded box at its corresponding price row in the indicator pane.
2. Three-Row Visual Layout
The indicator displays three horizontal rows of phase boxes: Weekly (top), Daily (middle), and 90-Minute (bottom). Each row is independently togglable. The boxes are sized proportionally and colored using configurable per-phase colors. Phase labels (A, M, D, X) are centered within each box.
3. Resonance Scoring
When two or more timeframe levels are in the same phase simultaneously, the resonance score increments. Score of 3/3 means weekly, daily, and 90-minute phases all show the same letter — a maximum alignment event. The background shading activates at 3/3 alignment to flag the condition visually.
4. Fibonacci Time Zone Projection
From the start of each new trading day, the indicator projects Fibonacci time ratios (1.0, 1.272, 1.618, 2.0, 2.618) forward using a configurable time unit (90-minute, daily 6H block, or full day). These projections appear as vertical dotted lines with ratio labels. They mark the temporal points where price structure has historically been more likely to change character.
5. Historical Phase Visibility
A toggle controls whether prior days' boxes remain visible or are hidden as each new period begins. With history enabled, the full phase map is visible across the visible chart range, providing context for how phases have sequenced in the past.
Features
Three-level phase mapping: Weekly, daily, and 90-minute Quarterly Theory phases displayed simultaneously
Configurable phase colors: Accumulation, Manipulation, Distribution, and X colors independently adjustable
Resonance score (1-3): Counts how many timeframe levels are in the same phase
3/3 alignment background: Gold background tint when all three levels align
Fibonacci time zone projection: Five Fibonacci ratios projected forward from session open
Configurable Fib time unit: 90-min, 6H, or daily unit for projection scaling
Historical phase boxes: Toggle to show or hide prior periods' phase mapping
Row labels: Left-edge labels identifying each horizontal row
Dashboard: Current weekly, daily, and 90-min phase, resonance score, and Fib time unit
Three alerts: Full resonance (3/3), new daily quarter, new weekly quarter
Input Parameters
General:
Show Historical Quarters: Toggle past period box visibility (default: false)
Auto-Detect Border Color: Adapts box border to chart background luminosity
Quarterly Cycles:
Show Weekly / Daily / 90-Min toggles
Show Phase Labels toggle
Label Size: Tiny, Small, Normal, or Large
Per-phase color inputs (A, M, D, X)
Fibonacci Time Zones:
Show Fibonacci Time Zones toggle
Fib Time Source: 0 = 90-min unit, 1 = daily 6H unit, 2 = weekly day unit
How to Use This Indicator
Step 1: Identify the Current Phase at Each Level
Check the dashboard rows for weekly, daily, and 90-minute phase. Each phase has a behavioral implication in Quarterly Theory: A = ranging accumulation, M = engineered spike against the prior move, D = directional distribution, X = reversal or continuation.
Step 2: Use the Resonance Score
A 3/3 resonance reading means all three time levels are in the same phase. The background shading triggers at this condition. Cross-timeframe alignment amplifies the behavioral tendency associated with that phase.
Step 3: Watch Fibonacci Time Projections
Fibonacci time ratios project when structural turning points may occur based on elapsed session time. Price approaching a projected Fib line while also in a key phase provides temporal context for setup timing.
Indicator Limitations
Quarterly Theory describes observed behavioral tendencies, not mechanical guarantees — the same phase can produce different outcomes depending on higher-timeframe context
Fibonacci time projections are probabilistic reference zones, not precise reversal targets
The three-level phase structure works best on liquid instruments during regular trading hours; crypto markets with no session boundaries produce less distinct phase behavior
Originality Statement
The simultaneous three-level Quarterly Theory phase renderer with a resonance scoring system and Fibonacci time zone projection in a single Pine Script v6 publication is the original contribution. The resonance score — quantifying cross-timeframe phase alignment from 1 to 3 — adds an analytical layer not present in standalone ADMX or ICT quarterly theory tools.
Disclaimer
This indicator is provided for educational and informational purposes only. It is not financial advice. Quarterly Theory phase labels are observational frameworks and do not predict price direction. Trading involves substantial risk of loss.
-Made with passion by jackofalltrades
Indicator

Stochastic Resonance Signal [JOAT]Stochastic Resonance Signal
Introduction
Stochastic Resonance Signal is an open-source indicator built on the physical principle of stochastic resonance — the counterintuitive phenomenon where a moderate level of random noise actually enhances the detection of weak periodic signals rather than degrading it. In trading terms: markets with low volatility noise may suppress trend signals, while a calibrated level of volatility noise can help reveal underlying directional structure.
This indicator computes a signal-to-noise score that normalizes a smoothed price derivative against ATR-based noise. The score peaks when a meaningful directional signal is present within a noise environment that is neither too quiet (which produces false flatness) nor too loud (which obscures the signal entirely).
Core Concepts
1. Signal Component
The raw signal is the smoothed rate of change of price — the first derivative of a filtered price series. An EMA is applied to close to produce a noise-reduced price, then the bar-to-bar difference of that EMA serves as the signal. Positive signal indicates upward momentum; negative indicates downward:
float emaPrice = ta.ema(close, i_signalLen)
float rawSignal = emaPrice - emaPrice
float normSig = rawSignal / (ta.stdev(rawSignal, i_normLen) + 0.0001)
The signal is normalized by its own rolling standard deviation, making it dimensionless and comparable across instruments.
2. Noise Component
Noise is defined as ATR normalized by its rolling standard deviation. This separates the volatility component from the directional component. When noise is very low, it contributes little penalty. When noise is very high, it heavily discounts the signal. The optimal noise range produces the highest SR score:
float noisePenalty = ta.stdev(atrVal, i_normLen) / (ta.sma(atrVal, i_normLen) + 0.0001)
float srScore = math.abs(normSig) / (1.0 + noisePenalty)
3. SR Score and Threshold
The final SR score combines signal strength divided by noise penalty. The score is plotted as a histogram and compared against a configurable threshold. When the score exceeds the threshold in the positive signal direction, a bullish event fires. When in the negative direction, a bearish event fires. Both require barstate.isconfirmed.
4. Regime Context
The indicator categorizes the current noise state as Low, Optimal, or High. The Optimal zone — where stochastic resonance theory predicts signal enhancement — is highlighted in the background. Signals fired during the Optimal noise zone are the primary intended use case.
Features
Normalized signal derivative: EMA-smoothed price rate of change, dimensionless
ATR noise penalty: Volatility normalized by its own distribution, not a fixed threshold
SR Score histogram: Visual representation of the signal-to-noise ratio each bar
Threshold crossover signals: Bull and bear signals when SR score exceeds the gate
Noise regime classification: Low, Optimal, and High noise zones labeled
Optimal zone background: Chart shading during the resonance-optimal noise window
Candle coloring: Candles tinted by current SR score direction and magnitude
Dashboard: Current SR score, signal value, noise level, and regime state
Alerts: Configurable bull and bear SR threshold crossing alerts
Input Parameters
Signal Engine:
Signal EMA Length: Smoothing for price derivative calculation (default: 10)
Normalization Length: Rolling window for z-score normalization (default: 50)
Noise Engine:
ATR Period: ATR length for noise estimation (default: 14)
Optimal Noise Low: Lower bound of optimal noise zone (default: 0.3)
Optimal Noise High: Upper bound of optimal noise zone (default: 0.8)
Signal Gate:
SR Score Threshold: Minimum SR score to fire a signal (default: 1.5)
How to Use This Indicator
Step 1: Identify the Noise Regime
Check whether the background shading is active (Optimal zone). Signals fired during optimal noise conditions have the theoretical backing of stochastic resonance theory behind them.
Step 2: Read the SR Score
A rising histogram above the threshold line in positive territory indicates a developing bullish signal. Crossing below the negative threshold indicates a bearish signal.
Step 3: Apply as a Momentum Filter
Use SR score direction to confirm or reject signals from other tools. An SR score rising strongly above its threshold while a support level holds adds conviction to a long setup.
Indicator Limitations
Stochastic resonance as a trading construct is a theoretical analogy, not a proven quantitative edge on its own
The optimal noise zone boundaries are heuristic; the true optimal noise level varies by instrument and timeframe
Normalization requires a minimum lookback before scores stabilize — expect less meaningful output in the first normLen bars
Originality Statement
The application of stochastic resonance theory to price signal detection — computing a signal-to-noise ratio using a normalized price derivative divided by an ATR noise penalty, with an explicit optimal noise zone classification — is an original analytical framing not found in existing published Pine Script indicators. This is not a standard oscillator; it is a physics-inspired signal processing approach adapted to price data.
Disclaimer
This indicator is provided for educational and informational purposes only. It is not financial advice. The stochastic resonance framework is a conceptual model and does not guarantee profitable signals. Trading involves substantial risk of loss.
-Made with passion by jackofalltrades
Indicator

Orderflow Imbalance Pressure [JOAT]Orderflow Imbalance Pressure
Introduction
Orderflow Imbalance Pressure is an open-source indicator that estimates the imbalance between buying and selling pressure on each bar without access to real bid-ask data, derives a Z-score normalized delta oscillator from that estimate, tracks cumulative delta over the session, and detects structural divergences between price extremes and delta behavior at confirmed pivot points.
The core analytical insight is that when price reaches a new high while the cumulative buying pressure behind it is declining, the move is potentially unsupported — buyers are diminishing while the market is being pushed to new levels. Conversely, price making new lows while selling pressure contracts suggests exhaustion rather than conviction. These divergences are objectively measurable and provide leading context that price action alone does not.
Core Concepts
1. Delta Estimation from OHLC
True tick-level delta (bid volume minus ask volume) requires raw tick data. This indicator estimates it from bar data using the classic candle ratio method: buying pressure is proportional to how close the close is to the high, and selling pressure to how close it is to the low:
float buyVol = rng > 0.0 ? volume * (close - low) / rng : volume * 0.5
float sellVol = rng > 0.0 ? volume * (high - close) / rng : volume * 0.5
float delta = buyVol - sellVol
This is an approximation — not a substitute for real order flow data — but provides a directionally useful signal on instruments where tick data is unavailable.
2. Delta Z-Score Normalization
Raw delta varies in scale across instruments and volume conditions. The indicator normalizes delta by computing a rolling Z-score: the delta minus its period mean, divided by its period standard deviation. This produces a dimensionless oscillator centered at zero:
float deltaZ = deltaStd > 0.0 ? (delta - deltaMA) / deltaStd : 0.0
Extreme Z-score readings above +1.5 or below -1.5 indicate statistically significant delta imbalances relative to recent history.
3. Cumulative Delta
Delta values are accumulated across the session to track the net buying or selling bias since session open. The cumulative delta line is scaled and overlaid on the histogram for context. Session resets are configurable (None, Session, or Manual). The cumulative delta often reveals sustained institutional bias that individual bar delta obscures.
4. Imbalance Threshold Markers
When the delta ratio (delta divided by total volume) exceeds a configurable threshold (default 0.6 = 60% of volume in one direction), the bar is classified as an extreme imbalance. Triangle markers appear at these bars and the background is lightly tinted. Extreme imbalance bars often mark exhaustion points or momentum bursts.
5. Pivot-Confirmed Divergence Detection
Divergences are detected using confirmed structural pivots rather than rolling high/low lookbacks. A bullish divergence requires a confirmed pivot low that is lower than the prior confirmed pivot low, while the cumulative delta at that pivot is higher than at the prior one. This fires a signal only at genuine structural turning points — typically 5–10 signals per extended chart rather than hundreds:
if not na(pivotLow)
float dAtPivot = cumDelta
if pivotLow < lastPivLow and dAtPivot > lastPivLowDelta
bullDiv := true
Features
OHLC-based delta estimation: Buy and sell volume proxy from candle structure
Z-score normalized oscillator: Delta normalized by rolling mean and standard deviation
Gradient histogram: Bars colored by delta direction and magnitude intensity
Cumulative delta overlay: Net session delta as a scaled line on the oscillator
Session reset modes: None, Session boundary, or Manual reset options
Extreme imbalance markers: Triangle shapes at bars exceeding the delta ratio threshold
Pivot-confirmed divergences: Bull and bear divergences fired only at structural pivot points
Dashboard: Current delta, bias, buy volume, sell volume, cumulative delta, and Z-score
Six alert conditions: Bull/bear imbalance, bull/bear divergence, delta surge bull/bear
Input Parameters
Delta Engine:
Delta Smoothing EMA: Smoothing for delta oscillator line (default: 3)
Delta Normalization Length: Z-score rolling window (default: 20)
Imbalance Threshold: Delta ratio required for extreme marker (default: 0.6)
Cumulative Delta:
Show Cumulative Delta toggle
Reset Mode: None, Session, or Manual (default: Session)
Cumulative EMA Smooth: Smoothing for cumulative line (default: 5)
Signal Settings:
Delta Divergence Signal toggle
Divergence Lookback: Base period for pivot divergence detection (default: 20)
How to Use This Indicator
Step 1: Read the Delta Bias
Check the dashboard's Bias row. BUYING PRESSURE, SELLING PRESSURE, or BALANCED reflects the current delta ratio. Use this to understand whether the current bar's volume is dominated by buyers or sellers.
Step 2: Watch the Cumulative Delta Trend
A rising cumulative delta line during a price advance confirms the move is volume-supported. Declining cumulative delta during a price advance is a warning sign that buyers are weakening.
Step 3: Act on Divergence Signals
When a DIV label appears (bullish or bearish), a confirmed structural pivot has formed with a diverging cumulative delta. This is the primary signal output of the indicator — use it to anticipate potential turning points in price.
Step 4: Note Extreme Imbalance Bars
The triangle markers at extreme imbalance bars often coincide with momentum exhaustion (after a sustained run) or momentum ignition (at a breakout). Context determines which interpretation applies.
Indicator Limitations
OHLC delta estimation is a proxy; it does not capture true bid-ask imbalance and will systematically differ from actual order flow data
On instruments with wide spreads or gaps, the candle ratio delta estimation becomes less reliable
Divergences in strong trends often resolve with further trend continuation before the divergence is acted upon
Cumulative delta resets at session boundaries, so intraday and multi-day comparisons require switching reset modes
Originality Statement
The combination of OHLC delta estimation, Z-score normalization, cumulative session delta with configurable resets, and pivot-confirmed divergence detection — requiring structural pivot confirmation rather than rolling lookback extremes — in a single publication is the original contribution. The pivot-gated divergence detection specifically prevents the signal spam common in delta divergence tools that use rolling high/low comparisons.
Disclaimer
This indicator is provided for educational and informational purposes only. It is not financial advice. Delta estimation from OHLC data is an approximation. All signals are based on historical data and do not guarantee future results. Trading involves substantial risk of loss.
-Made with passion by jackofalltrades
Indicator

Momentum Saturation Zones [JOAT]Momentum Saturation Zones
Introduction
Momentum Saturation Zones is an open-source indicator that detects when momentum has reached an extreme and then begins pulling back, marks the price level where that extreme occurred as a zone, and tracks the zone's structural validity until price either respects or invalidates it. The premise is that momentum peaks and troughs at significant price levels leave structural imprints — areas where the market demonstrated conviction — that subsequently act as reference points for support or resistance.
The key differentiator from a simple overbought/oversold indicator is the composite strength scoring: a zone is only created when a configurable minimum score is reached, incorporating the momentum extreme level, the magnitude of the pullback, volume at the peak bar, and whether a divergence is present.
Core Concepts
1. Multi-Source Momentum
The momentum signal is selectable from five sources: RSI, Rate of Change (normalized), MFI, Stochastic RSI, or a composite average of all four. The composite mode averages RSI, normalized ROC, MFI, and StochRSI into a single signal, reducing single-indicator noise while retaining each component's contribution:
float momSeries = (rsiRaw + rocNorm + mfiRaw + stochD) / 4.0
2. Adaptive Pullback Detection
The saturation trigger fires when momentum has pulled back from a rolling peak by more than a configurable percentage threshold. The threshold is adaptive — scaled by the current ATR relative to its 50-bar average. In high-volatility regimes the required pullback is larger; in low-volatility regimes it is smaller. This prevents premature triggers in noisy markets and late triggers in calm ones.
3. Composite Strength Scoring (0-100)
Each potential zone is scored before creation. The score combines four components: how extreme the momentum peak was (0-40 points), how far beyond the threshold the pullback reached (0-20 points), the volume ratio at the peak bar relative to average (0-20 points), and whether momentum divergence is present (0-20 points). Only zones meeting the minimum score gate are created:
float extrem = math.max(0.0, math.min(40.0, (peakAbsMom - 50.0) * 40.0 / 50.0))
float pbScore = math.max(0.0, math.min(20.0, (actualPb - adaptPct) * 2.0 + 10.0))
float volScore = math.max(0.0, math.min(20.0, (volRatio - 1.0) * 20.0))
float divScore = bearDiv and i_useDiv ? 20.0 : 0.0
4. Zone Anchor Logic
Bear resistance zones are anchored at the candle high of the peak bar with the zone extending upward by one ATR multiple — the bottom edge sits exactly at the candle high so price must reach up to touch the zone. Bull support zones are anchored at the candle low of the trough bar with the zone extending downward — the top edge sits at the candle low so price must come back down to touch it.
5. Zone Lifecycle and Touch Counting
Each zone tracks how many times price has returned to it (touch counter displayed in the label). When price closes beyond the invalidation offset, the zone is deleted entirely — no ghost boxes remain. A proximity check before creation prevents duplicate zones from stacking at the same price level.
Features
Five momentum sources: RSI, ROC, MFI, StochRSI, or Composite average
Adaptive pullback threshold: ATR-normalized trigger scaled to current volatility regime
Composite strength scoring (0-100): Extremity, pullback depth, volume, and divergence components
ATR-anchored zones: Three-layer gradient zones (outer, mid, core) with center line
Proper candle anchoring: Resistance bottoms at candle high; support tops at candle low
Touch counting: Zone labels update each time price retests the zone
Proximity deduplication: No duplicate zones within 1.5 ATR of same-side existing zones
Clean invalidation: Zones deleted entirely on invalidation — no ghost boxes
Divergence detection: Momentum divergence contributes bonus points to strength score
Candle coloring: Candles tinted when price is inside or within 0.5 ATR of a valid zone
Dashboard: Momentum value, pullback threshold, volatility regime, active zone count, and directional strength scores
Input Parameters
Momentum Configuration:
Momentum Source: RSI, ROC, MFI, StochRSI, or Composite (default: Composite)
Momentum Length: Period for all momentum calculations (default: 14)
Peak Lookback Bars: Rolling window for peak/trough detection (default: 50)
Saturation Trigger:
Adaptive ATR Threshold toggle (default: on)
Pullback % from Peak: Required pullback to trigger (default: 10%)
RSI Overbought/Oversold: Absolute extreme levels for gate (default: 70/30)
Cooldown Bars: Minimum bars between zone creation events (default: 10)
Zone Settings:
Max Active Zones: Simultaneous zone cap (default: 4)
ATR Length: ATR period for zone sizing (default: 14)
Zone Width (x ATR): Zone height as ATR multiple (default: 1.0)
Invalidation Offset %: Margin beyond zone for invalidation trigger (default: 0.3%)
How to Use This Indicator
Step 1: Read the Zone Strength
Zones display their strength score (0-100) in the label. Higher-scoring zones represent confluences of multiple factors and are historically more likely to produce price reactions.
Step 2: Use Touch Count for Context
A zone touched twice and holding is more significant than a freshly-created zone. A zone touched three or more times that eventually breaks is exhausted — expect the break to accelerate.
Step 3: Watch for Candle Color Changes Near Zones
The candle coloring activates when price enters the zone or comes within 0.5 ATR of it. This provides a passive alert that price is approaching a structural reference.
Indicator Limitations
Momentum peaks do not always coincide with price extremes — the zone is placed at the price of the peak momentum bar, which may differ from the highest/lowest price in the lookback
In strongly trending markets, zones on the trend side may be repeatedly invalidated as trend continues
The strength score is a composite heuristic, not a backtested predictor of zone success rate
Originality Statement
The composite strength scoring system — combining momentum extremity, pullback depth, volume, and divergence into a single 0-100 gate — applied to zone creation is the original analytical contribution. The proper candle-edge anchoring (resistance bottom at candle high, support top at candle low), proximity deduplication, and clean deletion on invalidation are implementation details not present in most published support/resistance zone indicators.
Disclaimer
This indicator is provided for educational and informational purposes only. It is not financial advice. Momentum saturation zones are historical reference levels and do not predict future price reactions. Trading involves substantial risk of loss.
-Made with passion by jackofalltrades
Indicator

Confluence FVG Finder | ProjectSyndicateConfluence FVG Finder automatically identifies and validates high-probability, non-repainting Fair Value Gaps. It filters for structural quality using an ATR-based imbalance filter, normalizes all zone heights for consistency, and embeds a live multi-timeframe confluence engine inside every zone to provide a quantifiable, data-driven edge.
🧠 Live Multi-Timeframe Engine — This is not a single-timeframe tool. Every FVG zone displayed on the chart is the result of a live, proximity-based confluence engine scanning three independent higher timeframes (default H1, H2, H4) simultaneously. Each label shows exactly how many timeframes confirmed the zone, its composite strength rating (0–10), the session it formed in, its age, and its exact pip height, giving you an instant structural edge.
🎯 Imbalance-Validated FVGs — The engine doesn't just mark any three-candle gap. It validates each Fair Value Gap on the higher timeframes by requiring the gap to exceed a user-defined multiple of ATR, filtering out insignificant micro-gaps and focusing only on imbalances that reflect true market-moving intent before they are even considered for merging.
🎨 ATR-Normalized Zones — Eliminates visual noise from inconsistent gap sizes. This feature forces every merged FVG zone to a uniform, ATR-based height (e.g., 0.75x ATR). This provides a clean, consistent chart and allows for a more objective analysis of price interaction with zones of equal visual weight, preventing oversized gaps from distorting the chart.
📊 Proximity-Based Merging — Timeframes rarely align perfectly to the pip. The confluence engine uses an intelligent ATR-based proximity tolerance to detect when Fair Value Gaps from different timeframes are clustered in the same price territory. It then mathematically merges them into a single, high-probability "Confluence Zone," ensuring you don't miss valid setups due to minor price discrepancies across timeframes.
✅ Chart-Timeframe Independent — The engine's credibility comes from its architectural stability. Each timeframe is detected entirely inside its own data context and every zone is anchored to the timestamp it formed on, so — unlike standard MTF indicators that repaint or shift zones depending on the chart you are viewing — the merged zones are mathematically identical whether you view them on a 5-minute, 15-minute, or 1-hour chart.
🔧 Fully Customizable — Control every aspect of the engine, including the 3 target timeframes (default H1 / H2 / H4), the Minimum Timeframe Confluence threshold (e.g., require 3 out of 3 TFs), the Proximity Tolerance multiplier, the Minimum Strength Filter, the per-timeframe strength bonus, the mitigation mode (Touch / Full Fill / 50% Fill), and the colors/visibility of Bullish and Bearish zones.
🔬 Why this algo is unique: Standard FVG indicators are subjective — often just shading every three-candle gap on the current timeframe with no proof of higher-timeframe alignment. The Confluence FVG Engine transforms this into an objective, multi-dimensional instrument. It doesn't just show you a gap; it proves the imbalance is backed by aligned intent across multiple timeframes, merging them into a single, undeniable area of interest on the exact chart you are viewing.
🌐 Apply to Gold (XAUUSD), Indices (US30, NAS100), Forex Majors, and Crypto. With the default H1 / H2 / H4 structure, execute from any timeframe at or below H1 (1m–1h) while the engine tracks the H1, H2, and H4 imbalances. The engine is designed for assets that exhibit clear impulsive moves and respect deep supply/demand dynamics.
🗂️ How to use this? The most critical metrics are the Timeframe Confluence Count and the Strength Rating. A zone confirmed by 3 timeframes with a Strength of 8.0+ indicates a massive structural edge. Consider only taking trades from these high-confluence zones that align with the prevailing higher-timeframe trend. The embedded label also shows the exact "pips away" distance, allowing for precise limit order placement. Note: Timeframe 1 is the anchor — keep your chart at or below it (H1 by default) so zones render exactly; an on-chart warning appears if your chart timeframe is set higher.
⚙️ IMPORTANT NOTICE: This indicator is a professional-grade tool designed to identify structural confluence. It should NOT be used as a standalone signal for entering trades blindly. Always use it in conjunction with your own trading strategy, price action analysis, and strict risk management to confirm trade setups. Indicator

Kalman Trend Filter [JOAT]Kalman Trend Filter
Introduction
Kalman Trend Filter is an open-source trend detection indicator that applies a two-state Kalman filter to price, tracking both the filtered price level and its velocity simultaneously. Unlike exponential moving averages — which apply a fixed exponential decay to past data — the Kalman filter dynamically adjusts its responsiveness based on the ratio of process noise to measurement noise. When price is moving consistently in one direction, the filter trusts new measurements more heavily. When price is noisy, it trusts its own model more heavily.
The practical result is a trend line that responds faster than an equivalent EMA during genuine trends while remaining smoother during chop. The velocity state is the direct indicator of trend direction and strength — it is what drives signal generation and candle coloring.
Core Concepts
1. Two-State Kalman Filter
The filter tracks two quantities: price (position state) and the rate at which price is changing (velocity state). The prediction step projects both states forward using simple kinematic equations. The correction step updates them based on how much the current close deviates from prediction:
// Prediction
float xPred = xEst + vEst
float pPred = pEst + qNoise
// Kalman gain
float kGain = pPred / (pPred + rNoise)
// Correction
float xEst = xPred + kGain * (close - xPred)
float vEst = vEst + kGain * (close - xPred)
The process noise (qNoise) and measurement noise (rNoise) parameters control how much the filter trusts its own momentum model versus new price data.
2. Velocity as Trend Proxy
The velocity state is the most analytically useful output. Positive velocity means the filtered price is accelerating upward; negative means downward. The magnitude of velocity indicates trend strength. Velocity crossing zero is a higher-quality trend reversal signal than a moving average crossover because it reflects the momentum of the filtered series, not the level.
3. Gradient Candle Coloring
Candles are painted using a two-sided gradient driven by the velocity state. Strongly positive velocity produces bright cyan candles; strongly negative produces bright magenta. Near-zero velocity transitions to neutral. The gradient intensity scales with velocity magnitude rather than applying a binary color switch.
4. Velocity Oscillator
The velocity state is plotted as a separate sub-indicator below the main chart, providing a visual oscillator that crosses zero at trend reversals. Unlike momentum oscillators derived from price differences, this oscillator represents the Kalman filter's internal estimate of trend rate — it is inherently smooth without additional EMA smoothing.
Features
Two-state Kalman filter: Tracks price level and velocity simultaneously
Configurable noise parameters: Process and measurement noise control filter responsiveness
Filtered price line overlay: Smooth trend line drawn on the price chart
Velocity oscillator: Kalman velocity state as a zero-line oscillator
Velocity zero-cross signals: Bull and bear signals when velocity crosses zero
Gradient candle coloring: Cyan for upward velocity, magenta for downward, scaled by magnitude
Dashboard: Current filtered price, velocity, trend state, and noise parameters
Alerts: Velocity zero-cross and extreme velocity alerts
Input Parameters
Kalman Engine:
Process Noise (Q): How much the filter trusts its own velocity model (default: 0.01)
Measurement Noise (R): How much the filter trusts new price measurements (default: 1.0)
Initial Velocity: Starting velocity state (default: 0.0)
Display:
Show Filter Line toggle
Show Velocity Oscillator toggle
Show Candle Color toggle
How to Use This Indicator
Step 1: Read Velocity Direction
Positive velocity (oscillator above zero, cyan candles) indicates the filter is trending upward. Negative velocity (below zero, magenta candles) indicates downward trend. The magnitude tells you how strong.
Step 2: Use Velocity Zero-Cross as Trend Change Signal
When velocity crosses from negative to positive, the filter's internal momentum model has flipped bullish. This is more reliable than a price crossover because it reflects the rate of change of the filtered series.
Step 3: Tune Noise Parameters to Timeframe
On faster timeframes, increase Q slightly (0.02–0.05) to make the filter more responsive. On weekly charts, reduce Q (0.001–0.005) for a smoother, slower-adjusting filter.
Step 4: Combine with Regime Context
The Kalman filter performs best in trending regimes. Combine with Fractal Dimension Oscillator: when FDO shows a trending regime, Kalman velocity direction provides the trend bias.
Indicator Limitations
The Kalman filter assumes a linear motion model; non-linear price dynamics (sudden gaps, news events) produce temporary distortion in the filter state
Optimal Q and R values are instrument and timeframe dependent; no universal setting works everywhere
Velocity zero-crosses during low-volatility consolidation can produce frequent false signals
Originality Statement
The two-state Kalman filter implementation combined with a velocity-driven gradient candle coloring system, a dedicated velocity oscillator, and dual-input noise parameter configuration in a single publication is the original contribution here. Most published Kalman filter scripts on PulseWire implement a single-state position filter with no velocity tracking and no gradient visualization.
Disclaimer
This indicator is provided for educational and informational purposes only. It is not financial advice. Kalman filter outputs are mathematical estimates based on prior observations and do not predict future price. Trading involves substantial risk of loss.
-Made with passion by jackofalltrades
Indicator

Institutional Flow Sentinel [JOAT]Institutional Flow Sentinel
Introduction
Institutional Flow Sentinel is an open-source market structure tool that tracks two categories of price behavior that institutional order flow leaves behind: Fair Value Gaps and liquidity sweeps. Both concepts originate from ICT (Inner Circle Trader) methodology, but this implementation combines them into a single unified engine with a live zone lifecycle, composite state tracking, and candle coloring — none of which are standard in most published FVG or sweep tools individually.
The core insight is that large participants need liquidity to fill orders. They engineer moves through external swing highs and lows to trigger retail stop orders, collect that liquidity, then reverse. Identifying these events in real time, tracking whether the gap or sweep level has been respected or violated, and classifying the current order flow bias from those events is the purpose of this indicator.
Core Concepts
1. Fair Value Gap Detection
A Fair Value Gap is a three-candle imbalance where the middle candle's range is not overlapped by the adjacent candles. Bullish FVGs form when a candle's low is above the high two bars prior. Bearish FVGs form when a candle's high is below the low two bars prior:
bullFVG = low > high
bearFVG = high < low
Each gap is stored with its price bounds and tracked bar-by-bar. If price returns and closes inside the gap the zone is marked mitigated and drawn differently. Unmitigated gaps project forward as active imbalance reference levels.
2. Liquidity Sweep Detection
The indicator tracks pivot highs as Buyside Liquidity (BSL) and pivot lows as Sellside Liquidity (SSL). A sweep occurs when price wicks through the level but then closes back inside it — indicating the liquidity was taken and price rejected:
bslSweep = high > bslLevel and close < bslLevel
sslSweep = low < sslLevel and close > sslLevel
Sweep events are labeled on the chart and contribute to the cumulative order flow bias score.
3. Composite Bias Score
Each confirmed FVG and sweep increments or decrements a running bias counter. Bullish FVGs and bearish sweeps (stops run below, reversal up) add positive weight. Bearish FVGs and bullish sweeps add negative weight. The dashboard displays this composite score alongside the current structural bias.
4. Zone Lifecycle Management
Active FVG zones are extended bar by bar. When price mitigates a zone (closes inside it), the zone rendering switches to a dimmed style but remains visible as a historical reference. The indicator tracks the count of active unmitigated gaps on each side and displays them in the dashboard.
Features
Real-time FVG detection: Bullish and bearish imbalances identified and drawn as price-bound boxes
FVG mitigation tracking: Zones update styling when price returns into the gap
BSL and SSL level tracking: Pivot-based liquidity levels updated each bar
Sweep event labels: On-chart labels at every confirmed liquidity sweep with direction
Composite order flow bias: Running score combining FVG and sweep events
Candle coloring: Candles painted by current bias state (bullish / bearish / neutral)
Institutional dashboard: Top-right table showing active FVGs, sweep count, and bias score
All signals on confirmed bars: barstate.isconfirmed throughout — no repainting
Input Parameters
Structure Detection:
Pivot Lookback: Bars required on each side for BSL/SSL pivot confirmation (default: 5)
Max Active FVGs: Maximum simultaneous FVG zones drawn per side (default: 3)
Display:
Show FVG Zones toggle
Show Sweep Labels toggle
Show Candle Color toggle
Show Dashboard toggle
How to Use This Indicator
Step 1: Identify Active Imbalances
Unmitigated FVG boxes mark price areas where a directional move was so strong that no two-sided trading occurred. Price tends to return and fill these gaps. Use them as magnet targets or potential reversal zones.
Step 2: Watch for Sweep Events
When a sweep label appears at a prior swing level, the indicator is signaling that liquidity at that level was collected. Sweeps followed by a strong close in the opposite direction are high-probability reversal setups.
Step 3: Read the Bias Score
The composite score in the dashboard quantifies accumulated institutional signals. A strongly positive score suggests the order flow is biased bullish; strongly negative suggests bearish. Use this as a directional filter.
Indicator Limitations
FVGs form on every timeframe and many will not be mitigated; not every gap is tradeable
Sweep detection uses close-back confirmation which adds one bar of delay
The bias score is a heuristic, not a statistically validated predictor of future direction
This indicator identifies market structure events; it does not generate entry or exit signals
Originality Statement
This indicator is original in combining FVG zone lifecycle management, pivot-based liquidity sweep detection, and a composite order flow bias score into a single Pine Script v6 publication. The zone mitigation tracking system, which distinguishes between active and mitigated imbalances while keeping both visible with different rendering, is not present in most standalone FVG tools on PulseWire.
Disclaimer
This indicator is provided for educational and informational purposes only. It is not financial advice or a recommendation to buy or sell any financial instrument. Trading involves substantial risk of loss. All signals are based on historical price data and do not guarantee future results. Always use proper risk management.
-Made with passion by jackofalltrades
Indicator

Fractal Dimension Oscillator [JOAT]Fractal Dimension Oscillator
Introduction
Fractal Dimension Oscillator is an open-source market geometry classifier that computes the fractal dimension of a price series using the Katz method and derives the Hurst exponent from it. The fractal dimension measures how much a price series fills space — a perfectly straight line has dimension 1.0, while a completely random walk approaches 2.0. Values between these extremes encode whether price is behaving in a trending, random, or mean-reverting fashion at the current moment.
The Hurst exponent H is derived as H = 2 - FD. Values above 0.5 indicate persistent trending behavior; values below 0.5 indicate mean-reverting behavior; H near 0.5 indicates a random walk. This gives traders an analytically grounded way to distinguish market regimes that directly determines which type of strategy applies.
Core Concepts
1. Katz Fractal Dimension Method
The Katz method computes fractal dimension from the total path length of price movements divided by the maximum distance traveled from the starting point:
// L = total path length, d = max distance from first point, n = N-1
float fd = math.log(n) / (math.log(n) + math.log(L / d / n))
This is computationally efficient compared to methods requiring fractal level decomposition and produces stable results across the configurable lookback period. The formula ensures that as price moves more linearly (large L relative to d), FD approaches 1.0. As price moves chaotically (small d despite large L), FD approaches 2.0.
2. Five-State Regime Classification
The raw FD value maps to five regime states based on configurable thresholds. The default boundaries are: Strong Trend (FD < 1.33), Trending (1.33–1.45), Random Walk (1.45–1.55), Mean-Reverting (1.55–1.67), Strong Mean-Revert (FD > 1.67). Each state carries a distinct color and strategy implication.
3. FD Percentile Tracking
The current FD value is ranked against a 100-bar rolling window to produce a percentile score. This shows not only the current regime state but how extreme that reading is relative to recent history — a 95th percentile trending reading is more significant than a borderline one.
4. Candle and Background Coloring
Candles are painted using a gradient: amber/gold for trending states, neutral for random walk, teal/cyan for mean-reverting states. Chart background is tinted faintly in the corresponding regime color. Both color channels update in real time as FD changes.
Features
Katz fractal dimension calculation: Computationally efficient geometric method
Hurst exponent display: H = 2 - FD, shown alongside raw FD in dashboard
Five-state regime classification: Strong Trend through Strong Mean-Revert
Smoothed EMA overlay: Optional EMA of raw FD for noise reduction
Regime transition markers: On-chart triangle shapes at every regime change
FD percentile (100-bar): Shows how extreme the current reading is historically
Gradient candle coloring: Amber for trend, teal for mean-revert, neutral center
Regime background tinting: Chart background reflects current regime state
Dashboard: FD, Hurst, regime, percentile, and strategy bias recommendation
Five alert conditions: Regime transitions and extreme readings
Input Parameters
Fractal Engine:
Fractal Period: Lookback bars for FD calculation (default: 30, range: 10-200)
EMA Smoothing: Smoothing period for the display line (default: 5)
Thresholds:
Trending Threshold: Hurst value above which market is trending (default: 1.5)
Mean-Revert Threshold: Hurst value above which market is strongly mean-reverting (default: 1.6)
How to Use This Indicator
Step 1: Read the Strategy Bias
The dashboard's Strategy Bias row gives a direct instruction: USE TREND SIGNALS, USE MEAN-REV SIGNALS, or AVOID / WAIT. This summarizes the regime into an actionable filter.
Step 2: Use Regime Transitions as Mode Switches
When a TREND triangle appears after a period of RANGE, consider activating trend-following setups. When a RANGE transition appears after trend, consider rotating to mean-reversion approaches.
Step 3: Check the Percentile
A 90th-percentile trending reading suggests a particularly directional market. A 10th-percentile trending reading is borderline — apply less conviction to trend signals.
Indicator Limitations
Fractal dimension is a mathematical property of the price series, not a predictive indicator — it describes what has happened, not what will happen
The Katz method is one of several FD estimation approaches; results will differ from Higuchi or other methods
Short lookback periods produce noisier FD values; longer periods produce smoother but slower-responding readings
Originality Statement
The Katz fractal dimension method is applied here in a complete regime classification engine with five states, EMA smoothing, a 100-bar percentile ranking, gradient candle coloring, and a strategy bias recommendation layer — none of which are standard in simple FD implementations. The combination of Hurst exponent derivation, percentile context, and strategy bias output in a single publication distinguishes this from generic fractal dimension scripts.
Disclaimer
This indicator is provided for educational and informational purposes only. It is not financial advice. Fractal dimension values describe historical price geometry and do not predict future price movement. Trading involves substantial risk of loss.
-Made with passion by jackofalltrades
Indicator

Entropic Structure Bands [JOAT]Entropic Structure Bands
Introduction
Entropic Structure Bands is an open-source overlay indicator that dynamically selects the best-fitting Ordinary Least Squares regression window from recent structural pivots and surrounds that regression channel with entropy-adjusted deviation bands. The key innovation over standard regression channel indicators is twofold: the window length is selected optimally each bar by searching through available pivot anchors for the highest R² × log(N) quality score, and the band width is modulated by the current Shannon entropy of log returns — widening during chaotic periods and tightening during orderly ones.
Core Concepts
1. Optimal Regression Window Search
Rather than using a fixed lookback, the indicator records the bar index of every confirmed pivot high and low. Each bar, it tests several candidate windows anchored at recent pivots and selects the one that maximizes a performance score: R² multiplied by the natural log of the window length. This rewards both fit quality and window depth simultaneously:
float score = r2 * math.log(float(N))
// highest score wins; window updates every bar
if trial.perfScore > bestScore
bestScore := trial.perfScore
bestMdl := trial
The regression channel therefore adapts to where significant price structure has occurred, not to an arbitrary fixed period.
2. Shannon Entropy Modulation
Shannon entropy of the log return distribution is computed using a histogram-binning approach. Low entropy means returns are concentrated — price is moving in an organized, directional way. High entropy means returns are evenly distributed — chaotic, noisy conditions. Band width scales with entropy:
float entAdjDev = bestMdl.stdErr * (1.0 + entNorm * 0.8)
When entropy is low (below the configurable threshold), the market is classified as orderly and signals are enabled. This prevents signals from firing into chaotic conditions where regression bands have less predictive value.
3. Trend-Confluence Signal Logic
Signals require simultaneous alignment of six conditions: regression slope direction, price position relative to midline, recent pullback to the inner band, momentum confirmation, optional HTF slope alignment, optional ADX trending gate, and optional RSI gate. Each condition is individually toggleable. This multi-factor gate replaces simple band-crossover logic with a structured confluence requirement.
4. Forward Projection
The regression channel extends forward by a configurable number of bars beyond the right edge of the chart. A projection target label marks the estimated price at the end of the projection window based on the current slope and intercept. This gives visual context for where the regression model expects price to be if the current trend continues.
5. Z-Score Candle Coloring
Each candle's position within the channel is expressed as a Z-score (standard deviations from the regression midline). Candles far above the midline (overbought extension) are tinted bear-color; candles far below (oversold extension) are tinted bull-color. This provides immediate visual context for where price stands within its current regression structure.
Features
Dynamic regression window: Optimal window selected each bar from pivot anchor scan
R² quality gate: Configurable minimum R² prevents low-fit windows from being used
Entropy-adjusted bands: Band width scales with Shannon entropy of log returns
Multi-factor signal gate: Six independently configurable confluence conditions
Forward projection: Channel extended beyond right edge with target label
Z-score candle coloring: Candles painted by standard deviation position in channel
Inner and outer bands (±1σ, ±2σ): Gradient-filled channel layers
Glow-effect midline: Double-drawn center line with transparency for depth
10-row dashboard: R², entropy, Z-score, duration, HTF alignment, ADX, RSI, signal state
JSON webhook alerts: Alert messages formatted as JSON with EP, TP, SL, and R²
Input Parameters
Regression Engine:
Pivot Scan Horizon: Number of pivots to evaluate as regression anchors (default: 20)
Pivot Sensitivity: Left/right bars for pivot confirmation (default: 5)
Min R² Quality Gate: Minimum fit quality to use a window (default: 0.50)
Band Multiplier 1/2: Inner and outer band standard deviation multiples (default: 1.0, 2.0)
Entropy System:
Entropy Lookback: Bars for entropy calculation (default: 20)
Entropy Bins: Histogram bins for return distribution (default: 10)
Low Entropy Threshold: Threshold below which market is classified as orderly (default: 2.5)
How to Use This Indicator
Step 1: Read the Slope Bias
Check the dashboard's Slope Bias row. BULLISH or BEARISH indicates the current regression direction. This is the primary directional input.
Step 2: Check Entropy State
LOW (orderly) entropy is the condition under which signals are most reliable. HIGH entropy warns that the regression model is operating in a chaotic environment.
Step 3: Wait for Signal Labels
LONG and SHORT labels appear only when the full confluence gate is satisfied. Each label shows entry price, TP1, TP2, stop loss, and R² quality.
Indicator Limitations
Regression channels repaint historically when the optimal window shifts to a new anchor; use the confirmed-bar signals for non-repainting entry logic
In markets with very few pivots, the scan horizon may find suboptimal windows with low R²
Shannon entropy requires sufficient lookback to produce stable estimates
Originality Statement
The dynamic pivot-anchored regression window search using R² × log(N) scoring, combined with Shannon entropy-modulated band width and a six-condition confluence signal gate, is the original analytical architecture of this publication. No existing published Pine Script regression channel indicator implements adaptive window selection from pivot anchors with entropy modulation in this manner.
Disclaimer
This indicator is provided for educational and informational purposes only. It is not financial advice. Regression channels are mathematical models of past price behavior and do not predict future price. Trading involves substantial risk of loss.
-Made with passion by jackofalltrades
Indicator

Dual Profile Structure Map [JOAT]Dual Profile Structure Map
Introduction
Dual Profile Structure Map is an open-source session volume profile indicator that computes Point of Control, Value Area High, Value Area Low, and Initial Balance levels for the current session and displays them as a horizontal histogram overlaid on price. Unlike fixed-range or visible-range profiles, this indicator uses time-based session segmentation — the profile represents only the bars within the current trading day, updating continuously as each bar closes.
The profile answers a specific question: where was the majority of trading activity concentrated in the current session, and what are the structural reference levels that follow from that activity? The Initial Balance (the range of the first hour of the session) provides context for whether subsequent price behavior is an extension or a rejection.
Core Concepts
1. Volume Profile Calculation
Price range is divided into configurable bins. Each bar's volume is allocated to the bins that overlap its high-low range, proportionally by the fraction of the bar that falls within each bin. The result is an array of volume-at-price values for the session:
for b = 0 to nBins - 1
float binLo = profileLow + b * binSize
float binHi = binLo + binSize
float overlap = math.min(high, binHi) - math.max(low, binLo)
if overlap > 0
vol_at_bin += volume * (overlap / (high - low))
2. Point of Control and Value Area
The Point of Control (POC) is the bin with the highest volume — the price level where the most trading occurred. The Value Area is computed using the standard 70% rule: starting from the POC, adjacent bins are added to the value area (choosing the higher-volume adjacent bin each time) until 70% of session volume is captured. The resulting Value Area High (VAH) and Value Area Low (VAL) define the range where value was accepted.
3. Initial Balance
The Initial Balance uses the high and low of the first configurable number of bars after session open (default: first 4 bars on a 15-minute chart = first hour). IB High and IB Low are drawn as horizontal lines across the chart. Price trading above IB High is bullish extension; below IB Low is bearish extension; inside the IB is balance.
4. Histogram Rendering
Volume bins are rendered as horizontal bars extending leftward from the right edge of the session. Bar width is proportional to relative volume. The POC bin uses a distinct color. Value area bins use a softer fill. Bins outside the value area use the dimmest fill. This creates the standard volume profile "bell curve" visualization.
Features
Session volume profile: Real-time per-session histogram updated bar by bar
Point of Control (POC): Highest-volume price bin with labeled line
Value Area (VAH/VAL): 70% volume concentration band with boundary lines
Initial Balance High/Low: First-session-period range with horizontal level lines
Configurable bin count: Controls granularity of the volume distribution
Session reset logic: Profile resets at each new session boundary
Candle coloring: Candles painted by position relative to POC and value area
Dashboard: Current POC, VAH, VAL, IB range, and session volume total
Input Parameters
Profile Configuration:
Number of Bins: Price level granularity for the profile (default: 24)
IB Bars: Number of bars defining the Initial Balance period (default: 4)
Session Type: Trading session boundary for profile reset
Display:
Histogram Width: Maximum bar width in chart bars (default: 30)
Show POC Line toggle
Show Value Area toggle
Show Initial Balance toggle
Show Candle Color toggle
How to Use This Indicator
Step 1: Identify the POC
The POC is the fair value anchor for the session. Price gravitating toward the POC during a pullback indicates healthy trend behavior. Price unable to hold above or below the POC suggests indecision at current levels.
Step 2: Use Value Area for Range Context
Value area acceptance means price is spending time within the 70% volume zone — a range-bound state. Value area rejection (price rapidly leaving VAH or VAL and not returning) indicates directional conviction.
Step 3: Trade Initial Balance Extensions
A close above IB High with follow-through is a bullish extension signal. A close below IB Low is bearish. Range expansion beyond the IB indicates participants accepting new value outside the opening equilibrium.
Step 4: Watch POC as Support or Resistance
On future pullbacks, the prior session's POC often acts as structural support or resistance. The indicator's persistent level lines provide these reference points across sessions.
Indicator Limitations
Volume profile interpretation requires practice; mechanical rules based on profile levels without context produce poor results
On instruments with irregular volume distribution (low-liquidity sessions, gaps), profiles may cluster into unrepresentative patterns
The 70% value area rule is a convention from Market Profile theory, not a mathematically proven optimal threshold
Originality Statement
The combination of a real-time session volume profile with Initial Balance tracking, candle coloring by value area position, and a live-updating dashboard in a single Pine Script v6 publication provides a self-contained session structure tool. The session-adaptive profile calculation using proportional volume allocation across bins is implemented from first principles, not adapted from another published script.
Disclaimer
This indicator is provided for educational and informational purposes only. It is not financial advice. Volume profile levels are historical references and do not guarantee future price reactions. Trading involves substantial risk of loss.
-Made with passion by jackofalltrades
Indicator

Arc Radius Trend [JOAT]Arc Radius Trend
Introduction
Arc Radius Trend is an open-source, overlay-based trend-following system that replaces the static ATR band of conventional supertrend-style indicators with a curved, acceleration-responsive radius. The band does not scale linearly with volatility alone — it also responds to how fast price is accelerating or decelerating, expanding when momentum surges and tightening when price action becomes uniform. This gives it a shape that mirrors how institutional participants view momentum: not as a constant envelope, but as one that breathes with the market.
The problem ART solves is over-sensitivity. Standard ATR-based trailing stops flip direction too freely during acceleration events, producing false exits at exactly the moment when the trend is strongest. By expanding the radius during acceleration, ART gives trends room to breathe without permanently widening the band for all conditions.
Core Concepts
1. Velocity and Acceleration from Price
ART computes price velocity as the EMA of the bar-to-bar change in close, and acceleration as the EMA of the change in velocity. Both use the same smoothing length. Acceleration is normalized by ATR so that it is dimensionless and comparable across instruments and timeframes:
velocity = ta.ema(ta.change(close), accelLength)
accel = ta.ema(ta.change(velocity), accelLength)
accelNorm = atr > 0 ? accel / atr : 0.0
2. Curved Radius Scaling
The base radius is ATR multiplied by a configurable multiplier. The acceleration norm is then used to scale that radius with a power function, creating a nonlinear expansion curve. The exponent (Curve Strength) controls how aggressively acceleration widens the band:
radiusScale = math.pow(1.0 + math.min(math.abs(accelNorm), 2.0), curvePower)
radius = atr * baseMult * radiusScale
3. Ratcheting Band Logic
The active band ratchets in the direction of the current trend. When price is above the band (bull), the lower band is preserved at its maximum achieved value, preventing it from retreating while the trend holds. The trend flips when price closes through the opposite band:
trend := close > upperBand ? 1 : close < lowerBand ? -1 : nz(trend , 1)
activeBand = trend == 1 ? lowerBand : upperBand
4. JOAT Institutional Expansion Layer
Each JOAT indicator carries a shared Expansion Layer — an adaptive spine built from price efficiency, Shannon entropy, Parkinson range volatility, and a market impact ratio. The spine tracks the dominant flow using an KAMA-style adaptive constant, and its width is scaled by ATR ratio, range volatility, and noise. Stress and calm rails extend beyond the outer context boundary and change color based on composite stress readings. Bull and bear regime shift nodes mark confirmed directional transitions in the expansion layer state.
Features
Curved radius expansion: Band width nonlinearly expands during price acceleration events
Ratcheting trend band: Lower band preserved on bull trend, upper band preserved on bear trend — no backward drift
Outer envelope: A second ring outside the active band provides an extended volatility reference
Trend-state candle coloring: Candles tinted to reflect current trend direction
Regime flip nodes: Circle markers on the active band at confirmed bull and bear regime transitions
JOAT Expansion Layer: Adaptive spine with efficiency/entropy scoring, context box, stress rails, calm rails, and shift nodes
Stress and calm telemetry rails: Outer halos that widen with impact ratio and volatility stress
Dashboard (top right): Live display of trend state, active band level, normalized acceleration, and last flip
All signals on confirmed bars: No repainting — all state changes fire only on barstate.isconfirmed
Input Parameters
Radius Model:
Radius ATR Length: ATR period for radius computation (default: 21)
Base Radius Multiplier: Baseline band width in ATR units (default: 2.4)
Acceleration Smoothing: EMA length for velocity and acceleration (default: 8)
Curve Strength: Power applied to acceleration scale — higher values expand the band more aggressively (default: 1.35)
Outer Envelope: Multiplier for the secondary outer ring (default: 1.65)
Display:
Trend-State Candles toggle
Show Dashboard toggle
JOAT Expansion Layer:
Efficiency, Entropy, Impact lengths; Adaptive Fast/Slow periods; Context Width
Spine, Context Box, Regime Nodes, Candle Tint, Projection Bars, and Opacity toggles
Independently configurable Bull, Bear, Neutral, and Accent colors
How to Use This Indicator
Step 1: Establish trend direction
Read the active band color and the dashboard. Green indicates bull trend; red indicates bear. Use this as the primary directional filter for entries.
Step 2: Watch for confirmed flip nodes
Circle markers at confirmed trend reversals mark the bar where the band direction changed. These are not entry signals — they are context anchors. Evaluate what triggered the flip (structural break, momentum loss) before acting.
Step 3: Use the outer envelope as a volatility reference
When price extends to the outer envelope, the market is in elevated acceleration. This is not necessarily a reversal signal — it may indicate trend continuation with excess momentum.
Step 4: Read the Expansion Layer spine
The JOAT spine color and state convey institutional flow independent of the ART band. Bull spine with bull ART band is high-confidence alignment. Divergence between the two (e.g., bull ART, neutral spine) suggests weakening conditions.
Indicator Limitations
Acceleration-driven radius expansion may produce very wide bands during high-velocity events, temporarily reducing the band's usefulness as a stop reference
The ratchet mechanism preserves the band in the trend direction — during prolonged consolidation, the band will not tighten until a directional break occurs
On very low-liquidity instruments, the ATR-based radius may be structurally noisy; increasing the ATR length reduces this
Arc Radius Trend does not generate entries. It identifies directional state and provides a trailing reference level
Originality Statement
Arc Radius Trend is original in its use of normalized price acceleration as a multiplicative, power-scaled modifier to ATR radius. Existing supertrend variants use static ATR multiples or linear volatility adjustments. The combination of:
Velocity → acceleration derivation applied to a curved radius (not a flat multiplier)
Power-function scaling that produces nonlinear radius expansion only during acceleration events
Ratcheting band logic that is conditioned on the curved radius (not a fixed channel)
An institutional expansion layer carrying efficiency, entropy, Parkinson range vol, and impact scoring as a second independent context layer
...makes ART a structurally distinct contribution rather than a parameter variation of existing published work.
Disclaimer
This indicator is provided for educational and informational purposes only. It is not financial advice or a recommendation to buy or sell any instrument. Trading involves substantial risk of loss. Past behavior of this indicator does not guarantee future results. All signals should be validated within a complete trading framework that includes risk management. The author is not responsible for trading losses resulting from the use of this indicator.
-Made with passion by jackofalltrades
Indicator

Risk Navigator Levels [JOAT]Risk Navigator Levels is an open-source Pine Script v6 overlay that turns confirmed trend-engine flips into a clean visual trade planning map. It draws an entry line, stop line, TP1, TP2, TP3, R-multiple labels, and optional risk/reward boxes after a confirmed setup.
The script is not a full trading system. Its purpose is visual planning: once its internal engine confirms a new long or short state, it freezes the entry, stop, and target levels so the user can inspect structure, distance, and status without manually drawing every line.
Core Concepts
1. Trend Engine Gate
The engine compares a fast EMA, slower EMA basis, ATR gate, and VWAP. A long setup requires the fast line above the basis, price above the upper gate, price above VWAP, and fast-line slope agreement. Shorts use the mirrored logic.
riseReady = fastLine > baseLine and close > upperGate and close > vwapLine and fastLine > nz(fastLine , fastLine)
fallReady = fastLine < baseLine and close < lowerGate and close < vwapLine and fastLine < nz(fastLine , fastLine)
2. Confirmed Direction Change
The script only creates a new level set when the engine direction changes on a confirmed bar.
confirmedLong = barstate.isconfirmed and engineDir == 1 and previousDir != 1
confirmedShort = barstate.isconfirmed and engineDir == -1 and previousDir != -1
3. Stop Selection
The stop is based on recent swing lookback and an ATR floor. This prevents the stop from being unrealistically tight relative to current volatility.
4. R-Multiple Targets
Once risk is calculated, TP1, TP2, and TP3 are plotted as multiples of that risk. The default values are 1R, 2R, and 3R.
5. Status Tracking
After a setup, the script tracks whether the stop or each target has been touched on confirmed bars and updates labels and dashboard status.
Features
Confirmed setup engine: Uses EMA, ATR gate, VWAP, and slope checks
Frozen entry and stop: Levels are created at setup time
TP1, TP2, TP3 targets: Target levels are R-multiple based
Risk/reward boxes: Optional green and red boxes show distance visually
Status labels: Shows whether SL, TP1, TP2, or TP3 has been touched
Right-edge labels: Keeps levels readable without crowding older bars
Dashboard: Shows mode, engine state, R size, targets, and status
Alerts: Setup, stop touch, and target touch conditions
Input Parameters
Visuals:
Palette Preset: Selects color pair
Level Reach Bars: Forward extension of lines and boxes
Risk/Reward Boxes: Toggles the boxes
Engine:
Source: Price source
Fast Length: Fast EMA length
Base Length: Slow EMA basis length
ATR Length: Volatility length
Confirmation Gate: ATR gate around the basis
Risk:
Stop Lookback: Swing lookback used for stop reference
ATR Stop Floor: Minimum stop distance multiplier
TP1 R / TP2 R / TP3 R: Target multiples
How to Use This Indicator
Step 1: Wait for a Confirmed Setup
The script draws a new plan only after its engine direction changes on a confirmed bar.
Step 2: Inspect R Size
The dashboard R size shows the distance between entry and stop. Large R size means the setup requires wider risk.
Step 3: Monitor Touch Status
Labels and dashboard status update when the stop or targets are touched after the setup bar.
Step 4: Use as a Planning Tool
The levels help visualize trade structure. They do not replace account-level risk controls.
Indicator Limitations
This is a visual planning tool, not a complete execution strategy
The engine can produce late signals during fast reversals
Targets are mathematical R levels, not forecasts
A stop touch and target touch can occur in the same bar on some candles; intrabar order cannot be known from closed OHLC alone
Originality Statement
Risk Navigator Levels is original in its integration of a confirmed trend gate, VWAP location, ATR stop floor, frozen R-level drawing system, and live status tracking. It is built as original Pine v6 code for transparent visual planning.
Disclaimer
This script is provided for educational and informational use only. It is not financial advice or a recommendation to buy or sell any financial instrument. Trading involves substantial risk of loss. Levels shown by the script are visual research levels and may not match actual execution conditions. Always use independent analysis and proper risk management.
-Made with passion by jackofalltrades
Indicator

Arc Trail Regime [JOAT]Arc Trail Regime is an open-source Pine Script v6 overlay that builds an accelerating trail around an adaptive EMA arc and gates directional flips with VWAP location. It is designed to show when price has crossed a dynamic trailing level while the broader value anchor agrees with the new side.
The script focuses on a smooth regime trail rather than many signal markers. It displays the active arc, a soft cloud, optional gradient candles, and right-edge shelf levels created after confirmed flips.
Core Concepts
1. Adaptive Arc Core
The core blends fast and slow EMA curves. The blend weight increases when recent speed and volatility expansion increase, which makes the arc respond faster during active movement.
speedRaw = math.abs(ta.ema(ta.change(sourceInput), 4)) / atrValue
volRatio = nz(ta.ema(atrValue, 5) / ta.ema(atrValue, 55), 1.0)
curveWeight = f_clamp(0.38 + speedNorm * 0.18 + volSpeed * 0.22, 0.25, 0.82)
arcCore = ta.ema(slowArc + (fastArc - slowArc) * curveWeight, 3)
2. VWAP Gate
Bull flips require price to be above VWAP. Bear flips require price to be below VWAP. This keeps the trail aligned with a basic value-location filter.
3. Accelerating Trail Width
The trail distance uses ATR and a volatility speed boost. During active movement, the trail can tighten within bounds so it reacts faster to regime changes.
4. Confirmed Flip Shelves
When a confirmed regime flip occurs, the script draws a shelf line near the flip bar. The shelf remains active until price invalidates it.
5. Distance Candles
Candles can be colored from bearish to bullish based on their normalized distance from the active trail.
Features
Adaptive arc core: Blends fast and slow curves by speed and volatility
VWAP-gated flips: Direction changes require price location agreement
ATR trail: Trail distance scales with chart volatility
Arc cloud: Soft band around the active trail
Active shelves: Right-edge support/resistance references after confirmed flips
Confirmed buy/sell flip markers: Compact BUY and SELL dots are offset away from candles and only print after confirmed regime flips
Gradient candles: Optional candle coloring by trail distance
Dashboard: Shows regime, VWAP side, distance, speed, and shelf status
Alerts: Confirmed bull flip and confirmed bear flip
Input Parameters
Visuals:
Palette Preset: Selects bull and bear colors
Arc Cloud: Shows the trail cloud
Gradient Candles: Enables candle coloring
Confirmed Flip Signals: Shows compact BUY and SELL flip markers
Active Shelves: Shows flip shelf lines and labels
Engine:
Source: Price source
Inner Curve Length: Fast EMA length
Outer Curve Length: Slow EMA length
ATR Length: Volatility length
Base Trail Width: Starting ATR trail multiplier
Volatility Speed Boost: Controls how much expansion affects the trail
How to Use This Indicator
Step 1: Read the Active Regime
The dashboard shows Bull or Bear based on the active trail side.
Step 2: Confirm VWAP Location
The VWAP row shows whether price is above or below the value gate used by the script.
Step 3: Monitor Shelves
Shelf lines are created after flips and can act as visual invalidation references.
Indicator Limitations
Trail systems can whipsaw during sideways markets
VWAP behavior varies across sessions and symbols
A shelf is a visual reference, not a complete stop model
Fast volatility shifts can temporarily widen or tighten the trail abruptly
Originality Statement
Arc Trail Regime is original in its adaptive arc weighting, VWAP-gated regime flips, speed-sensitive trail width, and active shelf visualization. It is built with original Pine v6 code and public chart data.
Disclaimer
This script is provided for educational and informational use only. It is not financial advice or a recommendation to buy or sell any financial instrument. Trading involves substantial risk of loss. Trail flips can fail in range conditions or during abrupt volatility changes. Always use independent analysis and proper risk management.
-Made with passion by jackofalltrades
Indicator

Adaptive Divergence Core [JOAT]Adaptive Divergence Core is an open-source Pine Script v6 oscillator that combines HMA-smoothed RSI behavior, adaptive percentile bands, confirmed divergence lines, and regime fills. It is designed to make oscillator extremes relative to the current chart sample instead of relying only on fixed overbought and oversold levels.
The script is useful when standard oscillator thresholds are too rigid. A market can stay strong or weak for long periods. Adaptive Divergence Core recalculates upper and lower fields from recent oscillator distribution, then plots confirmed divergence only after both price and oscillator pivots are confirmed.
Core Concepts
1. HMA-RSI Core
The oscillator blends RSI on raw price, RSI on HMA-smoothed price, and an HMA-smoothed RSI value. It is centered around zero for easier bullish and bearish reading.
hmaSource = ta.hma(src, hmaLen)
rawRsi = ta.rsi(src, rsiLen)
rsiOnHma = ta.rsi(hmaSource, rsiLen)
smoothedRsi = ta.hma(rawRsi, smoothLen)
core = (rsiOnHma * 0.58 + smoothedRsi * 0.42) - 50.0
2. Adaptive Percentile Bands
The upper and lower bands are calculated from rolling percentiles of the oscillator. This lets the bands adapt to the recent distribution of momentum.
upperRaw = ta.percentile_nearest_rank(core, percentileLength, upperPercentile)
lowerRaw = ta.percentile_nearest_rank(core, percentileLength, lowerPercentile)
3. Extreme Fields
Additional 95th and 5th percentile fields help show deeper oscillator stretch zones beyond the primary adaptive bands.
4. Confirmed Divergence Detection
Bearish divergence requires price to form a higher confirmed pivot high while the oscillator forms a lower confirmed pivot high. Bullish divergence requires price to form a lower confirmed pivot low while the oscillator forms a higher confirmed pivot low.
5. Regime Fill
The script fills the oscillator against zero and against its guide line, making positive and negative regimes easy to read without large markers.
Features
HMA-RSI oscillator: Blends raw RSI, RSI on HMA, and smoothed RSI
Adaptive percentile bands: Upper and lower thresholds adjust to recent oscillator behavior
Extreme bands: Additional outer fields for deeper stretch readings
Confirmed divergence lines: Divergences plot only after price and oscillator pivots confirm
Divergence labels: Small S Div and B Div labels are placed near confirmed divergence lines
Divergence line cap: Old lines are deleted to respect object limits
Optional candle tint: Can color chart candles from the oscillator pane setting
Dashboard: Shows core value, bands, divergence counts, and current field
Alerts: Divergence, band entry, and band release conditions
Input Parameters
Core:
Source: Price source
RSI Length: Base RSI period
HMA Price Length: HMA source smoothing
HMA RSI Smooth: Smoothing for the raw RSI component
Adaptive Bands:
Percentile Length: Lookback used for adaptive thresholds
Upper Percentile: Upper adaptive threshold percentile
Lower Percentile: Lower adaptive threshold percentile
Divergence:
Divergence Left Bars / Right Bars: Pivot confirmation settings
Maximum Divergence Lines: Object cap for plotted divergence lines
Divergence Labels: Shows or hides compact divergence labels
Visuals:
Tint Candles: Optional candle tint from the oscillator state
Show Dashboard: Shows or hides the compact top-right pane dashboard
Palette: Selects the local JOAT color preset
How to Use This Indicator
Step 1: Read the Core Relative to Zero
Values above zero show positive oscillator regime. Values below zero show negative oscillator regime.
Step 2: Use Adaptive Bands
When core enters the upper or lower adaptive band, momentum is stretched relative to its recent sample.
Step 3: Evaluate Divergence After Confirmation
Divergence lines are delayed by pivot confirmation. This is intentional and avoids projecting unconfirmed pivots into the past.
Indicator Limitations
Divergences confirm late because pivots need right-side bars
Adaptive bands depend on the selected lookback and can shift over time
Divergence is context, not a complete trade plan
During strong trends, oscillator stretch can persist for many bars
Originality Statement
Adaptive Divergence Core is original in its HMA-RSI blend, rolling percentile threshold system, confirmed pivot divergence logic, and compact dashboard. It uses public Pine v6 functions to build a distinct oscillator workflow.
Disclaimer
This script is provided for educational and informational use only. It is not financial advice or a recommendation to buy or sell any financial instrument. Trading involves substantial risk of loss. Oscillator divergences can fail or remain early for extended periods. Always use independent analysis and proper risk management.
-Made with passion by jackofalltrades
Indicator

Reaction Zone Ledger [JOAT]Reaction Zone Ledger is an open-source Pine Script v6 overlay that creates pivot-based support and resistance reaction zones, tracks signed volume pressure inside those zones, merges nearby zones, and displays compact statistics directly beside each active area.
The script is built for traders who want reaction zones to contain more information than a simple box. Each zone stores pressure, net impulse, touch count, state, and a dashed midpoint. The dashboard summarizes the broader signed-volume ledger and the nearest active zone.
Core Concepts
1. Signed Volume Proxy
Each bar receives a signed volume estimate from candle body bias and close location. This is not true buyer/seller volume; it is a transparent approximation from OHLCV data.
bodyBias = barRange > 0.0 ? (close - open) / barRange : 0.0
closeBias = barRange > 0.0 ? (((close - low) / barRange) - 0.5) * 2.0 : 0.0
signedVolume = volume * clamp(bodyBias * 0.62 + closeBias * 0.38, -1.0, 1.0)
2. Pivot Reaction Zones
Confirmed pivot highs create resistance-style zones. Confirmed pivot lows create support-style zones. The width is based on ATR so the zones scale with current chart volatility.
3. Merge Logic
When a new zone is close to an existing zone on the same side, the script merges them rather than stacking overlapping boxes. This keeps the chart cleaner and improves object efficiency.
4. Zone Ledger Statistics
Each zone tracks buy pressure, sell pressure, hit count, net impulse, and state. A small outside stats box displays the current pressure reading and net value.
5. Dashboard Summary
The dashboard shows overall ledger pressure, net impulse, nearest zone type, and nearest zone state.
Features
Pivot support and resistance zones: Zones are created from confirmed pivots
ATR-based width: Zone size adapts to volatility
Merge system: Nearby same-side zones combine into larger active areas
Signed-volume ledger: Tracks directional pressure using a transparent OHLCV proxy
Stats boxes: Pressure percentage, net impulse, and state displayed beside zones
Dashed midlines: Each zone has a center reference line
Dashboard: Shows active zone count and nearest zone context
Alerts: Support reaction, resistance reaction, and zone break
Input Parameters
Visuals:
Palette: Selects color pair
Show Dashboard: Toggles the top-right dashboard
Zones:
Pivot Left Bars / Pivot Right Bars: Pivot confirmation settings
Range Length: ATR length for zone sizing
Zone Half-Width ATR: Controls box thickness
Merge Distance ATR: Controls when nearby zones merge
Maximum Zones: Limits active object count
Forward Extension: Bars each zone extends forward
Ledger Impulse Length: Lookback for dashboard impulse stats
How to Use This Indicator
Step 1: Locate Active Zones
Green-style zones represent support reactions. Red-style zones represent resistance reactions.
Step 2: Read the Stats Box
The outside box shows whether the zone is testing, holding, cleared, lost, or mixed, along with its pressure value.
Step 3: Watch Break Alerts
A break alert means price closed beyond the zone boundary after previously trading around it.
Step 4: Use Nearest Zone Context
The dashboard helps identify whether price is closest to support or resistance and what state that zone is in.
Indicator Limitations
Signed volume is an approximation from OHLCV data
Pivot zones appear only after pivot confirmation
Merged zones can become wide during repeated tests
Zone pressure can change quickly when high-volume bars touch the zone
Originality Statement
Reaction Zone Ledger is original in its combination of confirmed pivot zones, merge logic, signed-volume accounting, outside stats boxes, and nearest-zone dashboard. It is original Pine v6 code and does not reuse another author's indicator source.
Disclaimer
This script is provided for educational and informational use only. It is not financial advice or a recommendation to buy or sell any financial instrument. Trading involves substantial risk of loss. Reaction zones can fail, widen, or become less useful in fast markets. Always use independent analysis and proper risk management.
-Made with passion by jackofalltrades
Indicator

Adaptive Volatility Envelope [QuantAlgo]🟢 Overview
The Adaptive Volatility Envelope wraps price in a dynamic field of volatility bands centred on a self-adjusting baseline. Rather than tracking price at a fixed speed, the centerline measures how efficiently price is moving and accelerates when movement is more directional while slowing down in choppy conditions, so the baseline follows sustained moves more closely and reacts less to sideways noise. Around this adaptive centerline, layered ATR-scaled bands form a heat map that brightens toward the side price is moving into, giving traders a visual read on both trend state and momentum strength across any instrument or timeframe.
🟢 How It Works
The indicator's core methodology combines two mechanisms: an efficiency-driven centerline that adapts its tracking speed to market conditions, and a volatility-scaled band field that visualises momentum through colour and brightness.
First, market efficiency is measured by comparing net directional movement against total movement over the adaptation window. This ratio approaches one when movement is more directional and falls toward zero in choppy conditions, and it is used to blend between a slow choppy speed and a fast trending speed. The result is a smoothing factor that automatically tightens the centerline's tracking in directional moves and loosens it in noise, without manual recalibration:
efficiencyRatio = totalMovement != 0 ? priceChange / totalMovement : 0.0
smoothingFactor = choppySpeed + (trendSpeed - choppySpeed) * efficiencyRatio
Next, the centerline advances toward price by the smoothing factor on each bar, producing an adaptive baseline that closes the gap quickly when efficiency is high and slowly when it is low:
centerline := na(centerline ) ? src : centerline + smoothingFactor * (src - centerline )
Band width is then derived from Average True Range scaled by the band spacing, with a safety cap that measures total envelope height against the recent fifty bar price range. If the raw width would exceed this cap, every band is scaled down proportionally, preventing the field from blowing out and distorting the chart scale during volatility spikes:
widthScale = rawWidth > maxWidth and rawWidth != 0 and maxWidth > 0 ? maxWidth / rawWidth : 1.0
bandUnit = atr * bandSpacing * widthScale
Momentum is resolved from the centerline's slope normalised by ATR and scaled by the colour sensitivity, then clamped to a range of minus one to one. This drives a gradient that runs from the neutral colour at flat momentum toward the bullish or bearish colour as the move strengthens, while a directional brightness offset lights up the leading side of the envelope more than the trailing side:
momentumRaw = not na(atr) and atr != 0 ? slope / atr * colorSens : 0.0
momentum = math.max(-1.0, math.min(1.0, momentumRaw))
Finally, a confirmed-bars toggle governs what the script computes. In Live mode the centerline, momentum, bands and signals update intrabar on the developing bar for the fastest response, with the current bar able to change until it closes. In Confirmed mode everything is locked to closed bars only, so signals do not repaint and print on the bar that closes the move.
🟢 Signal Interpretation
▶ Bullish Momentum (Centerline and Bands Brightening Toward the Bullish Colour): When the centerline slopes upward relative to volatility, momentum turns positive and the envelope gradient shifts toward the bullish colour. The leading upper side of the field brightens through the directional brightness offset, making the direction of the move easier to read. The bullish state persists as long as the centerline continues rising, and a "Momentum Turned Bullish" alert fires on the bar where momentum crosses above zero.
▶ Bearish Momentum (Centerline and Bands Brightening Toward the Bearish Colour): When the centerline slopes downward relative to volatility, momentum turns negative and the gradient shifts toward the bearish colour, with the leading lower side of the field brightening to flag the downturn. As with the bullish state, the colour saturates as the move strengthens and fades toward neutral as momentum flattens. A "Momentum Turned Bearish" alert fires on the bar where momentum crosses below zero, flagging a potential short or exit condition.
▶ Neutral Momentum (Centerline and Bands at the Neutral Colour): When the centerline is flat or moving slowly relative to volatility, momentum sits near zero and the gradient settles at the neutral colour at the middle of its range. This indicates low conviction or sideways drift rather than a directional move, and the envelope brightens away from neutral only as the slope steepens enough to register on either side. Reading the neutral state helps separate genuine momentum from chop, since the field stays muted until price generates a meaningful directional slope.
🟢 Features
▶ Preconfigured Presets: Three parameter sets cover a range of trading styles and timeframes. "Default" delivers a balanced engine for swing trading on 4-hour and daily charts. "Fast Response" shortens the adaptation window and quickens both market speeds for tighter, more reactive bands on 5-minute to 1-hour charts, suiting intraday and scalping use. "Smooth Trend" lengthens the adaptation window and slows the speeds for wider, steadier bands on daily and weekly charts, suiting position trading. The presets deliberately leave Volatility Length untouched, so band width stays under independent manual control.
▶ Built-in Alerts: Three alert conditions support automated monitoring of momentum transitions. "Momentum Turned Bullish" fires on the bar momentum crosses above zero. "Momentum Turned Bearish" fires on the bar momentum crosses below zero. "Any Momentum Change" triggers on either transition for traders who want a single unified alert regardless of direction. All alerts include the exchange, ticker, and timeframe in the message for immediate context, and the confirmed-bars toggle determines whether they evaluate on live or closed-bar data.
▶ Visual Customisation: Six colour presets, Classic, Aqua, Cosmic, Cyber, Neon, and Custom, provide coordinated bullish and bearish colour pairings suited to different chart themes and personal preferences. Selecting Custom exposes independent colour pickers for full manual control over both states, alongside an adjustable neutral colour for the midpoint of the gradient. The number of band layers is configurable from one for a clean minimal look up to eight for a rich gradient field, and the bands can be hidden entirely to display only the centerline. Optional bar colouring tints price candles with the active trend colour at a configurable transparency level, reflecting the current momentum state without reading the centerline directly.
Indicator

Order Pressure Cloud [JOAT]Order Pressure Cloud is an open-source Pine Script v6 overlay that estimates directional pressure from close location value, candle body bias, and volume participation. It then projects that pressure around an ALMA/EMA blended basis as a volatility-adjusted cloud.
The script is designed for pressure context. It does not read real order book data. Instead, it creates a transparent price-and-volume proxy that can show whether bars are closing toward highs or lows, whether volume is participating, and whether price is holding above or below the adaptive basis.
Core Concepts
1. Close Location Value
The close location value measures where the candle closes inside its high-low range. A close near the high produces positive pressure, while a close near the low produces negative pressure.
barRange = math.max(high - low, syminfo.mintick)
clv = ((close - low) - (high - close)) / barRange
2. Volume-Weighted Pressure
The script smooths CLV multiplied by volume and divides it by smoothed volume. This produces a normalized pressure ratio.
pressureNumerator = ta.ema(clv * volume, pressureLengthInput)
pressureDenominator = ta.ema(volume, pressureLengthInput)
pressureRatio = safeRatio(pressureNumerator, pressureDenominator)
3. Body Bias Component
Body direction is also included. The body component is weighted by a capped volume pulse so unusually large bars do not dominate the reading indefinitely.
4. Nonlinear Strength
The composite pressure is compressed with a nonlinear transform. This keeps extreme values readable and easier to display as a cloud strength score.
5. ALMA/EMA Basis Cloud
The basis blends ALMA and EMA. ATR, pressure strength, and volume pulse expand or contract the cloud width.
Features
CLV pressure proxy: Measures where price closes inside each candle range
Volume participation: Weights pressure by volume while normalizing by smoothed volume
Body pressure component: Adds candle body direction to the pressure model
Nonlinear strength scale: Converts pressure into a bounded -100 to +100 value
Adaptive cloud: Cloud width adjusts with ATR, pressure strength, and volume pulse
Basis blend: ALMA and EMA create a smoother central reference
Pressure zones: Confirmed pressure shifts and holds create clean boxes with pressure percentage and volume pulse data
Confirmed buy/sell labels: Compact labels mark pressure shifts and pressure-cloud holds after bar close
Strength gauge: Top-right dashboard shows pressure, volume, basis side, and cloud scale
Alerts: Pressure shifts, cloud holds, confirmed buy, and confirmed sell conditions
Input Parameters
Source: Price source for the basis
Pressure Length: Smoothing length for pressure calculations
Basis Length: Length for ALMA and EMA basis
ALMA Offset / ALMA Sigma: ALMA shape controls
ALMA Share: Blend weight between ALMA and EMA
ATR Length: Volatility length for cloud width
Cloud Multiplier: Base cloud distance
Signal Level: Strength threshold for pressure shifts
Paint Bars: Enables pressure candle tint
Strength Gauge: Shows dashboard
Pressure Zones: Toggles pressure data boxes
Buy/Sell Signals: Toggles compact confirmed labels
Zone Width: Bars each pressure box extends
Zone History: Maximum pressure boxes retained
Palette: Selects color pair
How to Use This Indicator
Step 1: Read the Gauge
The pressure row shows whether the current pressure score is above, below, or near neutral.
Step 2: Watch Basis Holds
A cloud hold means price interacted with the inner cloud while pressure remained directional.
Step 3: Compare Pressure With Price Location
Pressure is more meaningful when price is on the same side of the basis as the pressure reading.
Indicator Limitations
This is a price-and-volume proxy, not direct order book data
Volume availability differs between markets and symbols
Low-volume symbols can produce unstable pressure readings
Pressure shifts are reactive and can reverse during choppy conditions
Originality Statement
Order Pressure Cloud is original in how it combines CLV, body bias, volume pulse, nonlinear strength compression, and an adaptive ALMA/EMA cloud. It is built as original Pine v6 code from public market data fields.
Disclaimer
This script is provided for educational and informational use only. It is not financial advice or a recommendation to buy or sell any financial instrument. Trading involves substantial risk of loss. Pressure proxies can be inaccurate, especially where volume data is incomplete or irregular. Always use independent analysis and proper risk management.
-Made with passion by jackofalltrades Indicator

Impulse Memory Engine [JOAT]Impulse Memory Engine is an open-source Pine Script v6 overlay that measures fresh displacement, stores directional memory with exponential decay, and displays adaptive retest rails after significant impulse bars. It is built to answer a simple question: is the most recent meaningful impulse still fresh enough to matter?
The script blends MAD-style distance, ATR, trend basis, and decay memory. This creates a visual layer that distinguishes fresh impulse, fading impulse, and reset conditions while keeping the chart clean.
Core Concepts
1. MAD and ATR Normalized Displacement
The script estimates a robust distance unit using median absolute deviation and ATR. The impulse score is the one-bar displacement divided by this unit.
medianSource = ta.median(sourceInput, madLengthInput)
madDistance = ta.median(math.abs(sourceInput - medianSource), madLengthInput)
unitDistance = math.max(atrValue * 0.35, madDistance * 1.4826)
impulseRaw = safeRatio(sourceInput - sourceInput , unitDistance)
2. Trend Basis and Fast Track
A slower EMA defines the trend basis while a faster EMA tracks near-term movement. The distance between them contributes to the heat score.
3. Freshness Decay
When a bullish or bearish impulse appears, the script measures bars since that impulse and applies exponential decay. Fresh impulses have more weight; older impulses fade naturally.
bullBars = ta.barssince(bullImpulse)
bearBars = ta.barssince(bearImpulse)
bullFresh = na(bullBars) ? 0.0 : math.exp(-bullBars / decayLengthInput)
bearFresh = na(bearBars) ? 0.0 : math.exp(-bearBars / decayLengthInput)
memorySigned = bullFresh - bearFresh
4. Adaptive Bands
The trend band widens when memory strength increases. This helps separate quiet reset states from active impulse regimes.
5. Retest Rails
After a fresh impulse, the script stores a rail near the impulse bar. A confirmed retest occurs when price revisits the rail while memory remains directionally active.
Features
Impulse score: Measures displacement relative to MAD and ATR distance
Memory decay model: Tracks whether the last strong impulse is fresh or fading
Adaptive trend cloud: EMA basis and fast track are filled by memory state
Dynamic bands: Band width expands with volatility and impulse memory
Retest rails: Bull and bear rails remain visible for a configurable window
Rail labels: Active bull and bear rails are labeled at the right edge with spacing protection when both rails are close
Confirmed buy/sell labels: Compact BUY and SELL labels mark fresh impulse continuation or rail retest continuation on confirmed bars
Heat candles: Optional candle coloring by impulse and memory strength
Dashboard: Top-right panel shows impulse, memory, state, and rail status
Alerts: Fresh impulse, rail retest, confirmed buy, and confirmed sell conditions
Input Parameters
Source: Price source used for calculations
Trend Length: Slow EMA basis length
Fast Track Length: Faster EMA used inside the cloud
MAD Length: Median distance length
ATR Length: ATR distance length
Band Multiplier: Scales adaptive bands
Impulse Threshold: Minimum normalized displacement for a fresh impulse
Memory Half Window: Controls decay speed
Rail Visibility: Bars a rail remains eligible for retests
Heat Candles: Enables candle coloring
Dashboard: Shows or hides the top-right dashboard
Rail Labels: Shows active bull and bear rail labels
Buy/Sell Signals: Shows confirmed continuation signal labels
Palette: Selects the local JOAT color preset
Dashboard: Shows the panel
Palette: Selects color pair
How to Use This Indicator
Step 1: Read the Memory State
The dashboard state shows whether the script is tracking bull memory, bear memory, or resetting.
Step 2: Watch Fresh Impulse Events
Fresh impulse alerts show that displacement exceeded the configured threshold in the direction of the trend basis.
Step 3: Use Retest Rails
Rails act as reference levels after impulse. A retest is most meaningful when the dashboard memory state still agrees with the rail direction.
Indicator Limitations
Impulse detection is sensitive to the selected source and threshold
Very low volatility can make normalized movement appear larger
A rail retest is contextual and does not define risk by itself
The memory model fades old impulses; it does not predict the next impulse
Originality Statement
Impulse Memory Engine is original in its use of robust distance normalization, exponential impulse decay, adaptive bands, and retest rails in one compact overlay. It is built with original Pine v6 logic and public mathematical functions.
Disclaimer
This script is provided for educational and informational use only. It is not financial advice or a recommendation to buy or sell any financial instrument. Trading involves substantial risk of loss. Impulse readings can fail during choppy markets or sudden volatility shifts. Always use independent analysis and proper risk management.
-Made with passion by jackofalltrades
Indicator

Liquidity Sweep Probability [JOAT]Liquidity Sweep Probability is an open-source Pine Script v6 overlay that maps equal highs and equal lows, tracks sweeps through those levels, detects reclaim behavior, and records simple continuation samples after reclaim events. It is designed for traders who want a clean way to observe where price has built nearby liquidity and how price behaves after that liquidity is tested.
The script does not claim that a sweep must reverse price. Instead, it separates equal-level creation, sweep, reclaim, break, and continuation outcomes. The dashboard shows the most recent event, the side involved, sample counts, and an adaptive probability-style reading derived from the script's own observed samples.
Core Concepts
1. Equal High and Equal Low Detection
Confirmed pivots are compared against the previous pivot on the same side. If two pivot highs or lows are within an ATR-based tolerance, a liquidity zone is created.
pivotHigh = ta.pivothigh(high, pivotLength, pivotLength)
if not na(lastHighPivot) and math.abs(pivotHigh - lastHighPivot) <= equalTolerance
zoneTop = math.max(pivotHigh, lastHighPivot) + zonePadding
zoneBottom = math.min(pivotHigh, lastHighPivot) - zonePadding
2. Sweep State
A high-side sweep occurs when price trades beyond the equal high zone but closes back below the zone top. A low-side sweep occurs when price trades below the equal low zone but closes back above the zone bottom.
3. Reclaim State
After a sweep, the script watches a configurable reclaim window. A high-side reclaim requires price to close back below the lower boundary of the swept high zone. A low-side reclaim requires price to close back above the upper boundary of the swept low zone.
4. Continuation Sampling
After reclaim, the script stores a target distance based on ATR and tracks whether price reaches it within the outcome window. These counts are displayed as samples. They are descriptive statistics from the chart, not a prediction.
5. Probability Panel
The probability-style score blends observed sample rate, sweep distance, zone age, and reclaim status. It gives a compact read of the current event context.
sampleRate = total > 0 ? (wins * 100.0) / total : 50.0
score = clamp(sampleRate * 0.62 + 19.0 + distanceBoost + ageBoost + reclaimBoost, 5.0, 95.0)
Features
Equal high and equal low zones: ATR tolerance avoids exact-price-only matching
Sweep detection: Tracks confirmed high-side and low-side liquidity sweeps
Reclaim detection: Separates immediate breaks from reclaim behavior
Continuation samples: Counts historical reclaim outcomes within the active chart sample
Dashed midlines: Each zone includes a center reference line
Stateful labels: Zones update from Equal High/Low to Sweep, Reclaimed, or Broken
Probability panel: Shows side, status, chance value, samples, and age
Alerts: Sweep, reclaim, and zone break conditions
Input Parameters
Swings:
Swing Pivot Length: Pivot sensitivity for equal-level detection
Equal-Level Tolerance: ATR fraction used to compare pivots
Zone Padding: ATR fraction added around the equal level
ATR Length: Volatility length for tolerance and padding
Behavior:
Reclaim Window: Bars allowed for reclaim after sweep
Continuation Window: Bars allowed for measuring post-reclaim continuation
Continuation Distance: ATR target used for sample tracking
Maximum Zones Per Side: Object cap for high and low zones
Visual:
Palette: Selects bull and bear colors
Zone Extension Bars: Forward extension for boxes and midlines
Probability Panel: Shows or hides the dashboard
How to Use This Indicator
Step 1: Identify Equal-Level Zones
Equal highs can act as high-side liquidity references. Equal lows can act as low-side liquidity references.
Step 2: Watch for Sweep and Reclaim
A sweep alone is not enough. Reclaim behavior shows that price tested outside the zone and then closed back through the zone boundary.
Step 3: Read the Sample Count
The sample row shows how many observed reclaim events reached their ATR target on the current chart sample. A small sample should be treated carefully.
Step 4: Use Zones as Context
Use the zones to frame liquidity behavior, then combine the context with your own entry trigger and risk plan.
Indicator Limitations
Equal-level zones are based on confirmed pivots, so they appear after the pivot confirmation window
The probability value is descriptive and chart-dependent
A small number of samples should not be treated as statistically strong
Fast markets may sweep, reclaim, and break multiple zones quickly
Object limits require the script to delete older zones when caps are reached
Originality Statement
Liquidity Sweep Probability is original in its state machine for equal-level zones, sweep/reclaim/break classification, and live sample tracking. It uses public Pine v6 mechanics to build a self-contained liquidity map without copying another indicator's source.
Disclaimer
This script is provided for educational and informational use only. It is not financial advice or a recommendation to buy or sell any financial instrument. Trading involves substantial risk of loss. Liquidity sweeps can continue, reverse, or fail without warning. Always use independent analysis and proper risk management.
-Made with passion by jackofalltrades
Indicator

Kalman Auction Ribbon [JOAT]Kalman Auction Ribbon is an open-source Pine Script v6 overlay that builds a six-layer adaptive ribbon from a zero-lag source and Kalman-style velocity smoothing. The goal is to show trend alignment, slope strength, deviation zones, and confirmed retest behavior in one restrained chart layer.
The script focuses on auction behavior around a dynamic ribbon. When the ribbon layers align and slope together, the state becomes directional. When price stretches beyond the deviation envelope and then returns, the script can mark supply or demand zones for later retests.
Core Concepts
1. Zero-Lag Source
The source is adjusted by comparing current price with a half-length historical value. This produces a more responsive input for the ribbon calculations.
zeroLagOffset = math.max(1, int(math.round(baseLength * 0.50)))
zeroLagSource = src + (src - nz(src , src))
2. Kalman-Style Velocity Estimate
Each ribbon layer uses a compact velocity smoother that maintains an estimate and speed component. The speed term helps the estimate respond to directional movement without relying on future bars.
prior = na(estimate ) ? value : estimate + nz(speed ) * gain
error = value - prior
speed := nz(speed ) * (1.0 - alpha * 0.50) + error * alpha * gain
estimate := prior + error * alpha
3. Six-Layer Ribbon Alignment
The script calculates six different ribbon lengths. Alignment and slope scores are combined into a trend score from -100 to +100. This score controls the ribbon color and dashboard power reading.
4. Deviation Zones
Upper and lower deviation levels are built around the ribbon midpoint using ATR. If price pushes beyond a deviation level and closes back inside, the script creates a compact supply or demand zone.
5. Retest Logic
Retest signals occur when price interacts with a live zone or the ribbon itself while the ribbon state remains directional. These signals are confirmed on closed bars.
Features
Six-layer adaptive ribbon: Multiple Kalman-style layers reveal alignment and spread
Velocity weighting: Gain input changes how aggressively the smoother responds
Deviation envelope: ATR-based upper and lower zones around the ribbon midpoint
Soft supply and demand boxes: Created only on confirmed deviation rejection behavior, with overlap suppression so the chart does not stack redundant boxes
Labeled deviation boxes: Supply and Demand Deviation boxes include midpoint guide lines and fade after invalidation
Confirmed buy/sell markers: Compact BUY and SELL dots appear only after confirmed ribbon or zone retest behavior
Trend-state candles: Optional bar coloring by ribbon state
Dashboard: Shows state, power, distance, and retest status
Alerts: Confirmed buy, confirmed sell, lower deviation zone, and upper deviation zone
Input Parameters
Core:
Source: Price source used by the ribbon
Base Length: Main length from which all ribbon layers are derived
Velocity Weight: Strength of the speed component
Deviation ATR Length: ATR length for deviation zones
Deviation Width: ATR multiplier for the envelope
Zones:
Show Deviation Zones: Toggles supply and demand boxes
Zone Extension Bars: How far active boxes extend to the right
Maximum Zones Per Side: Caps active supply and demand boxes
Signals:
Show Confirmed Buy/Sell: Toggles compact confirmed signal dots
Signal Spacing Bars: Minimum spacing between signal markers
Zone Extension Bars: Forward box extension length
Maximum Zones Per Side: Object cap for zone storage
Visual:
Palette: Selects the color pair
Show Ribbon: Toggles ribbon plots and fill
Trend-State Candles: Enables candle coloring
Dashboard: Shows the top-right panel
How to Use This Indicator
Step 1: Read Ribbon Alignment
A strongly stacked ribbon with a high dashboard power value indicates directional alignment. A mixed ribbon shows a less decisive state.
Step 2: Watch Deviation Zones
Zones are created when price rejects beyond an ATR deviation envelope. These boxes represent areas where price stretched away from the ribbon and returned.
Step 3: Use Retests With Context
Retest dots identify confirmed interactions with the ribbon or zones. They should be evaluated with trend state, market structure, and risk placement.
Indicator Limitations
Kalman-style smoothing is reactive and does not know future price direction
Strong news bars can move through deviation zones without meaningful retests
Object limits require older zones to be removed when the maximum is exceeded
The ribbon can compress during range conditions and produce mixed readings
Originality Statement
Kalman Auction Ribbon is original in its combination of zero-lag preprocessing, six independent Kalman-style layers, ATR deviation boxes, and confirmed retest tracking. It uses public Pine primitives in a custom structure and does not paste or disguise another author's source.
Disclaimer
This script is provided for educational and informational use only. It is not financial advice or a recommendation to buy or sell any financial instrument. Trading involves substantial risk of loss. Ribbon states and zones can fail during unusual volatility or thin liquidity. Always use independent analysis and proper risk management.
-Made with passion by jackofalltrades
Indicator

VWAP Gravity Bands [JOAT]VWAP Gravity Bands is an open-source Pine Script v6 overlay that builds an anchored VWAP field with a smoothed T3 basis and ATR ladder bands. It is designed to show how far price has traveled from a session, weekly, or monthly value anchor, then classify that distance as center pull, ladder drift, expansion, or outer-band reaction.
The script is useful when a trader wants the chart to show both location and behavior around VWAP. Instead of a single VWAP line, it creates a full distance map around the anchor, colors candles by their distance from the basis, and highlights confirmed outer reactions without using arrow-style signal clutter.
Core Concepts
1. Anchored VWAP Selection
The anchor can reset on the session, week, or month. The script uses timeframe.change() to produce the reset pulse and ta.vwap() to calculate the anchored value.
anchorTimeframe = anchorChoice == "Week" ? "1W" : anchorChoice == "Month" ? "1M" : "1D"
anchorPulse = timeframe.change(anchorTimeframe)
rawVwap = ta.vwap(sourceInput, anchorPulse)
2. T3 Basis Smoothing
Raw anchored VWAP can move sharply at the beginning of an anchor period. VWAP Gravity Bands runs that value through a T3-style smoother to create a cleaner basis while preserving responsiveness.
e1 = ta.ema(src, length)
e2 = ta.ema(e1, length)
e3 = ta.ema(e2, length)
basis = c1 * e6 + c2 * e5 + c3 * e4 + c4 * e3
3. ATR Ladder Bands
The band ladder is based on ATR, not fixed percentages. This lets the distance field expand and contract with the market's current movement range.
ladderUnit = atr * bandStep
upperOne = basis + ladderUnit
lowerOne = basis - ladderUnit
upperThree = basis + ladderUnit * 3.0
lowerThree = basis - ladderUnit * 3.0
4. Distance State Model
Distance from VWAP is normalized by the ladder unit. The script classifies large directional continuation as expansion and failed outer-band tests as reactions.
5. Gradient Candle Coloring
Candles can be colored by their normalized distance from VWAP. This helps identify when price is balanced around the anchor, drifting away from it, or stretched toward an outer band.
Features
Session, weekly, or monthly anchor: Select the VWAP reset period from inputs
T3-smoothed VWAP basis: Cleaner centerline for visual trend and location analysis
ATR ladder bands: Three upper and lower bands scale with current volatility
Expansion state detection: Highlights directional movement away from the basis
Outer reaction detection: Marks confirmed failed tests near the outer ladder
Distance candle mode: Optional gradient candles based on normalized VWAP distance
Dashboard: Shows anchor, state, distance, ATR step, and basis slope
Alert conditions: Upper reaction, lower reaction, upper expansion, and lower expansion
Input Parameters
Visual System:
Palette Preset: Selects color pair
Distance Candles: Enables candle coloring by VWAP distance
Dashboard: Shows top-right state panel
Raw VWAP: Displays the unsmoothed anchored VWAP
Outer Reaction Marks: Shows compact TP-style outer reaction markers
VWAP Gravity:
Anchor: Session, Week, or Month
Source: Price source used for VWAP
T3 Basis Length: Smoothing length for the VWAP basis
T3 Factor: Controls T3 smoothness
ATR Length: Volatility length used for ladder distance
ATR Step: Distance between ladder bands
Expansion Step: Threshold for expansion classification
Reaction Step: Threshold for outer reaction classification
How to Use This Indicator
Step 1: Choose the Anchor
Use Session for intraday context, Week for swing context, and Month for broader value location.
Step 2: Read Distance From Basis
The dashboard distance value shows how many ladder units price is away from the smoothed VWAP basis.
Step 3: Separate Expansion From Reaction
Expansion means price is moving away from VWAP with slope confirmation. Reaction means price tested an outer area and closed back inside.
Step 4: Use the Bands as Context
The bands are not automatic entry levels. They show location. Combine them with market structure, candle behavior, and risk planning.
Indicator Limitations
VWAP is volume-based and may behave differently on symbols with sparse volume
The first bars after a new anchor can be less stable because VWAP is starting a new sample
Reaction markers show a confirmed close back inside a zone, not a future reversal forecast
ATR bands adapt to volatility but can widen quickly after large bars
Originality Statement
VWAP Gravity Bands is original in how it combines anchored VWAP selection, T3 smoothing, ATR ladder geometry, distance-colored candles, and separate expansion/reaction states. It is built from public Pine v6 functions and original logic rather than copied indicator source.
Disclaimer
This script is provided for educational and informational use only. It is not financial advice or a recommendation to buy or sell any financial instrument. Trading involves substantial risk of loss. VWAP location and band reactions can fail in trending, news-driven, or low-liquidity markets. Always use independent analysis and proper risk management.
-Made with passion by jackofalltrades
Indicator

Shift Structure Cloud [JOAT]Shift Structure Cloud is an open-source Pine Script v6 overlay that converts confirmed swing structure into a clean adaptive trend cloud. It tracks pivot highs and pivot lows, separates continuation breaks from character shifts, and uses the active structure range to build a dynamic average and multi-layer cloud around price.
The problem it solves is structural context. Many trend tools react only to moving averages or oscillator thresholds. This script anchors its visual state to confirmed market structure first, then uses an adaptive cloud to show whether price is trading above, below, or inside the current structural center. The result is a chart layer that can help separate continuation from transition without relying on future bars.
Core Concepts
1. Confirmed Pivot Structure
The script uses ta.pivothigh() and ta.pivotlow() to confirm swing highs and lows. A pivot is only accepted after the configured right-side confirmation window closes, which means the level is delayed by design but does not depend on unconfirmed future plotting.
pivotHigh = ta.pivothigh(high, pivotLeft, pivotRight)
pivotLow = ta.pivotlow(low, pivotLeft, pivotRight)
if not na(pivotHigh)
structureHigh := pivotHigh
2. BOS and CHoCH Logic
The current structure high and low become break reference levels. A bullish break occurs when price closes above the prior structure high. A bearish break occurs when price closes below the prior structure low. If the break happens against the previous side, it is classified as CHoCH; otherwise it is a continuation BOS.
bullBreakRaw = barstate.isconfirmed and not na(priorHigh) and close > priorHigh and priorClose <= priorHigh
bearBreakRaw = barstate.isconfirmed and not na(priorLow) and close < priorLow and priorClose >= priorLow
bullChoCh = bullBreak and trendSide == -1
bearChoCh = bearBreak and trendSide == 1
3. Adaptive Structure Average
Instead of plotting only fixed swing levels, the script calculates the midpoint between the active structure high and low. The midpoint is then smoothed with an adaptive alpha. When price moves far from the structural center, the average becomes more responsive; when price is balanced, it becomes slower.
structureMid = (activeHigh + activeLow) * 0.5
structureDrift = f_clamp(math.abs(close - structureMid) / legSize, 0.0, 1.0)
adaptAlpha = slowAlpha + (fastAlpha - slowAlpha) * structureDrift
structureAverage := structureAverage + adaptAlpha * (structureMid - structureAverage )
4. Multi-Layer Cloud
The cloud is built from ATR-adjusted bands around the adaptive structure average. Inner, middle, and outer layers give a visual read of compression, transition, and extended distance from structure.
5. Strength-Based Candle Coloring
When enabled, candles are repainted with a gradient based on distance from the structure average. The candle color is informational only; it does not change the underlying chart data.
Features
Confirmed BOS and CHoCH detection: Structural events are gated with barstate.isconfirmed
Adaptive structure average: A dynamic centerline based on active swing range and price drift
Layered trend cloud: Inner, middle, and outer ATR bands visualize distance from structure
Structure high and low levels: Current confirmed swing levels can be shown as reference lines
Gradient candle mode: Optional candle coloring by structural distance
Compact dashboard: Shows side, last shift, strength, bars since shift, and active range
Palette presets: Aqua Rose, Neon Desk, Mint Pulse, and VWAP Field
Alert conditions: Separate alerts for bullish BOS, bearish BOS, bullish CHoCH, and bearish CHoCH
Input Parameters
Visual System:
Palette Preset: Selects the bull and bear color pair
Color Candles: Enables structural candle coloring
Dashboard: Shows or hides the top-right dashboard
Pivot Dots: Shows confirmed pivot dots
Structure Engine:
Pivot Left / Pivot Right: Controls swing confirmation sensitivity
Fast Adapt Length: Fast smoothing response for the adaptive average
Slow Adapt Length: Slow smoothing response for balanced conditions
Cloud ATR Length: ATR length used for cloud width
Cloud Width: Multiplier applied to the cloud distance
BOS and CHoCH Marks: Shows structural event markers
Structure Levels: Shows active swing high and low reference lines
How to Use This Indicator
Step 1: Read the Cloud Side
If price is above the adaptive structure average and the cloud is colored bullish, the current structural state favors upside continuation. If price is below and the cloud is bearish, the state favors downside continuation.
Step 2: Watch CHoCH Events
CHoCH labels mark breaks against the previous structural side. They are useful as transition warnings, not automatic entries.
Step 3: Use the Structure Levels
The active high and low lines show where the next confirmed break could occur. These are the levels the script uses for BOS and CHoCH classification.
Step 4: Combine with Your Own Trigger
This script is designed as a structure and context layer. Use it with your own entry model, risk plan, and market selection process.
Indicator Limitations
Pivot levels confirm after the right-side pivot window closes, so they are intentionally delayed
A fast reversal can occur before a new pivot is confirmed
Cloud distance is ATR-based, so very low volatility markets can compress the visual bands
The script classifies structure; it does not predict future price movement
Originality Statement
Shift Structure Cloud combines confirmed BOS/CHoCH logic, an adaptive structure midpoint, ATR cloud geometry, and strength-colored candles in one original Pine v6 implementation. The script is not a pasted source clone. It rebuilds structure analysis from public Pine mechanics and adds a distinct visual model around the current swing range.
Disclaimer
This script is provided for educational and informational use only. It is not financial advice or a recommendation to buy or sell any financial instrument. Trading involves substantial risk of loss. Signals and structure readings are based on historical chart data and can be wrong in live market conditions. Always use independent analysis and proper risk management.
-Made with passion by jackofalltrades
Indicator
