Multi-Anchor_VWAP & Deviation Bands [AFD]
Three anchored VWAPs on one chart, with the price zones where they agree shaded in for you.
WHAT IT IS
An anchored VWAP shows the average price everyone has paid since a moment you pick - the gap open, the earnings bar, the swing low that started the move. That is where buyers from that moment sit at break-even, which is why price keeps coming back to it.
One anchor answers one question, so most traders end up dropping three or four by hand and dropping them again every session. This runs three at once: each anchors where you want, each carries its own deviation bands, and the script shades the zones where two of them line up.
THE CONFLUENCE SHADING
Look at this first. It does work you would otherwise do by eye.
When your session VWAP and your weekly VWAP arrive at the same price, that price is being watched by two different groups at once. Those levels tend to matter more than either line alone, and with three curves running they are easy to miss.
The script shades between any two layers that come within your tolerance of each other - on by default at 8 points, and it checks all three pairings, 1 to 2, 1 to 3 and 2 to 3.
Set the tolerance in ticks, points, currency, or percent of price. Trading more than one instrument, use percent: it is the only one you never have to re-tune when you change symbol.
THE ANCHORS
Ten per layer, mixed freely.
Set and forget - Session, Week, Month, Quarter, Year. Re-anchors itself every new period.
Pick the bar yourself - Manual timestamp. Type a date and time. This is the one for an earnings bar, a Fed day, a gap.
Let the chart find it - prior-session high or low, confirmed swing high or low. These follow structure so you are not re-anchoring by hand.
Defaults are session and week, the pairing most intraday traders want.
Two things about the structure anchors look broken if nobody warns you:
The curve shows up late. A swing is not a swing until enough bars print after it. At swing length 10 the line appears 10 bars after the pivot, then draws itself back to the pivot where it belongs.
It never rewrites history. When a newer pivot confirms, the layer re-anchors from there forward. Everything already drawn stays put.
THE BANDS
Up to three per layer, each with its own multiple from 0.0 to 10.0. They tell you how stretched price is from that anchored average. Four ways to measure the stretch:
Standard deviation (default) - how far price usually strays from this average. The classic VWAP band.
ATR - sized by recent range instead, so the envelope opens up in fast markets.
Percent of VWAP - a fixed percentage. Same shape on any instrument.
Standard error - starts wide on a fresh anchor and tightens as the window fills.
Type the multiples in, or load a Fibonacci preset: 0.382 / 0.618 / 1.0 for the inner set, 1.0 / 1.618 / 2.618 for the outer.
IT TELLS YOU WHEN IT CANNOT DO ITS JOB
An anchored VWAP can quietly stop being volume-weighted, or stop covering the window you think it does. This one writes it on the layer's own label, and these notes cannot be switched off - they show even with line labels turned off:
"UNWEIGHTED (no volume)" or "N bars unweighted" - the feed gives no usable volume, so this is a plain average, not a VWAP. Most indices and some spot forex. This is the one that matters.
"one bar per session" / "two-bar window" - a prior-session anchor on a daily or higher chart, where it can only ever span two bars.
"clipped to the draw depth" or "segment past the 5,000-bar buffer, not drawn" - the line starts in mid-air because it hit a drawing limit, instead of pretending it reaches further back than it does.
"(retro)" - a structure anchor, found after the fact. "RTH" - regular hours only, which changes what the average is.
A clean chart carries none of these. One showing up means something you could not otherwise see has happened.
SETTING IT UP
Add it. Layer 1 takes the session, layer 2 the week, and the shading marks where they agree.
Want one clean line? Switch layer 2 off. Want a third timeframe? Switch layer 3 on.
Anchoring to an event: Manual timestamp, then the bar's date and time. Anchoring to structure: a confirmed swing or a prior-session extreme.
Running two or three layers, turn on "Show anchor" - once bands overlap, a label naming its starting bar beats one that just says "L2".
84 inputs in seven groups, and anything that does not apply greys itself out.
ALERTS
One alert: VWAP crosses, band crosses, both, or off. Create it in PulseWire with "Any alert() function call". It only fires when a bar closes, never mid-bar, so you are not woken up by a wick that gets taken back.
WORTH KNOWING BEFORE YOU USE IT
Structure anchors draw late. That is the trade for anchoring to something only confirmable in hindsight.
History runs 5,000 bars, and draw depth caps how far a line reaches. Hit either and the label says so instead of the line quietly stopping short.
On "Regular hours only" the ATR bands still measure across every bar on the chart, so they use a wider set of bars than the average does.
"Current window only" hides older curves once a repeating anchor has cluttered things up. Fills, the prior-window level and the confluence shading switch off in that mode.
These bands are this script's own definition, not a claim of equivalence with anyone else's bands of the same name.
Not usable in the Pine Screener - the manual anchor needs a time input, and the Screener substitutes its default instead of reading it, so it would anchor from the wrong bar without telling you.
One symbol, one timeframe. No higher-timeframe or cross-symbol requests.
WHAT MAKES IT DIFFERENT
Three genuinely independent anchors - own anchor, own source, own colours, own bands. Not one anchor with presets.
Confluence shading across all three pairings, in four choices of unit.
It anchors to bars it can only recognise after the fact - prior-session extremes and confirmed swings - and back-fills the curve to them. A running-total VWAP cannot reach backwards like that without starting over.
It states its own failure modes on the chart instead of returning a number that is not what its name says.
Four band bases behind one band definition, and Fibonacci ratios as presets on the levels you already have rather than as extra clutter.
Open source under the Mozilla Public License 2.0. Indicator

VWAP Suite I EonMetricsVWAP Suite
VWAP Suite plots three independently anchored Volume-Weighted Average Price lines — Session, Weekly and Monthly — with volume-weighted deviation bands and the previous period's VWAP close kept on the chart as a reference level. Everything is computed from first principles at each anchor, so every line resets exactly where its period starts.
🔶 WHAT VWAP IS
VWAP is the average price of the period weighted by how much volume traded at each price. It answers one question: "what is the fair average price actually paid since the anchor?" That is why institutional execution desks benchmark fills against it, and why price so often reacts when it returns there — it is the level where the average participant in the period is at break-even. Above the VWAP the average buyer of the period is in profit; below it, under water.
🔶 WHAT IT DOES
Three anchors — Session (resets each trading day), Weekly and Monthly VWAP, each with its own toggle and color. Intraday traders typically work with Session, swing traders add Weekly, and Monthly serves as the higher-timeframe fair-value reference. Anchors that make no sense on the current chart timeframe (e.g. a Session VWAP on a daily chart) hide themselves automatically.
Deviation bands — ±1σ, ±2σ and optional ±3σ around ONE chosen anchor. The deviation is volume-weighted and anchored to the same period as the VWAP it wraps — not a rolling standard deviation — which is the statistically consistent way to band a VWAP (the same math PulseWire's built-in VWAP bands use). ±2σ is the classic stretched-price reference; the optional gradient fill keeps the zones readable without clutter.
Previous VWAP Close — the exact level where the Session (or Weekly) VWAP finished its previous period, drawn flat through the current one. The same idea as previous day high/low, but volume-based: yesterday's fair price is a natural magnet and reaction level for today. Few VWAP tools carry this level forward — it is the reason this suite exists.
🔶 HOW IT IS CALCULATED
From each anchor the script accumulates three sums bar by bar: volume × price, volume, and volume × price². VWAP = Σ(volume × price) / Σ(volume). The band deviation comes from the volume-weighted variance Σ(volume × price²)/Σ(volume) − VWAP². At every period rollover the previous VWAP value is captured first, then the sums reset to zero. Values only update on confirmed data — there is no repainting logic anywhere in the script.
🔶 ALERTS
Seven alert conditions: price crossing each of the three VWAPs, price touching the +2σ or −2σ band, and price crossing the previous Session or previous Week VWAP close.
🔶 HOW TO USE
1. Pick your anchors — Session for intraday, add Weekly for swing context.
2. Choose which anchor carries the deviation bands (Bands Around).
3. Keep Previous Session VWAP on — reactions at yesterday's fair price are the cleanest thing this tool shows.
4. Set alerts on the crossings you actually trade around.
🔶 SETTINGS
Source (price input, hlc3 default) · Anchors (Session / Weekly / Monthly, each with color) · Deviation Bands (anchor selector, ±1σ/±2σ/±3σ toggles, gradient fill) · Previous VWAP Close (Session / Weekly levels).
🔶 HONEST LIMITATIONS
On CFDs and spot forex the data feed reports TICK volume (number of price updates), not true traded volume. VWAP built on tick volume is still the standard practice on those markets and tracks the real one closely on liquid symbols, but you should know what feeds the math. On symbols with no volume data at all the script deliberately shows nothing rather than fake a line. VWAP is a descriptive average, not a prediction — this tool draws levels, it does not generate signals.
Part of the EonMetrics toolset.
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

AlgoStorm Institutional VWAP Suite (IVS)AlgoStorm Institutional VWAP Suite (IVS)
A multi-anchor, institutional-grade VWAP framework covering five distinct time horizons simultaneously — Daily, Rolling Time-Window, NY, European/London, and Asian/Pacific — with volume-weighted standard deviation bands, a configurable color suite, a live info table, and full alert coverage.
The AlgoStorm Institutional VWAP Suite (IVS) is built on a single conviction: VWAP is not a single line, it is a layered structural map. Professional traders and institutions do not reference one VWAP — they read the relationship between multiple anchored VWAPs across sessions and time windows to understand where the auction is relative to where it has been. IVS makes this entire multi-anchor framework available in one cohesive, configurable overlay, designed for futures, equities, forex, and any instrument with reliable volume data.
Why Multiple VWAPs?
Each anchor tells a different story. The Daily VWAP defines where the current session is balanced. The Rolling VWAP reflects dynamic equilibrium over a configurable time window, acting as a responsive benchmark for swing and position traders. The session VWAPs — NY, London, and Asia — reveal the price acceptance or rejection developing within each regional trading block. When price holds above the NY VWAP but stalls beneath the Daily VWAP, that tension itself is actionable information. IVS maps all five references simultaneously so those relationships are always visible.
Technical Architecture
Each VWAP anchor is computed through a dedicated VwapInstance User-Defined Type (UDT). This object maintains the running sums required for both the VWAP price and the volume-weighted population standard deviation, using the mathematically correct formula σ² = E − E ² . Deviation bands derived from this are true volume-weighted standard deviations — not ATR estimates or fixed percentage offsets.
The Rolling VWAP runs on a High-Fidelity Sliding Time-Window Engine . Rather than anchoring to a calendar boundary, it maintains four parallel arrays (price-volume, volume, squared price-volume, and timestamps) to continuously evict data older than the user-defined window. This produces a genuinely time-accurate rolling VWAP at any timeframe, not a bar-count approximation.
Session resets (NY, London, Asia) use a one-minute anchor window via time("1", range, timezone) , which fires accurately across all chart timeframes — not just 1-minute charts.
Features & Functionality
Daily VWAP: Anchors at each calendar day open using hlc3 as the price source. Resets correctly on the first bar of every session including overnight gaps. Paired with optional volume-weighted standard deviation bands (two configurable multipliers for ±1σ and ±2σ levels).
Daily VWAP Wave (H/L): Plots two companion VWAPs anchored to the daily high and low respectively, with a filled channel between them. This "wave" shows the intraday auction range as a structural envelope rather than a single midline — price inside the wave indicates balance, price outside indicates initiative direction.
Rolling Time-Window VWAP: Fully configurable window in days, hours, and minutes. Defaults to 1 day. Paired with optional volume-weighted standard deviation bands. Unlike a fixed daily anchor, the rolling VWAP adapts continuously, making it a natural trend reference for intraday and swing traders.
NY Session VWAP: Anchors at 09:30 ET (New York open). The primary reference for equities and US futures RTH participants. Resets each session regardless of the chart's display timezone.
European / London Session VWAP: Configurable anchor at either 03:00 ET (London) or 02:00 ET (Frankfurt). Essential for tracking European institutional participation, particularly on DAX and EUR/USD.
Asian / Pacific Session VWAP: Configurable anchor at either 20:00 ET (Tokyo) or 18:00 ET (Sydney). Useful for establishing overnight reference levels and identifying the range that NY will either accept or reject at the open.
Color Suite: Every line has an independently configurable color input. The defaults (Silver, White, Blue, Lime, Red, Yellow) are chosen for visual hierarchy on dark themes, but each can be adjusted for light themes, personal preference, or multi-indicator setups.
Live VWAP Info Table: An optional on-chart table (top-right, togglable) displaying the current numeric value of all six active VWAP levels, color-coded to match their respective lines. Values display as — for any anchor that has not yet reset in the current session. Populated only on the last bar to avoid unnecessary per-bar overhead.
10 Alert Conditions: Cross-above and cross-below alerts for every VWAP line. Alerts fire on bar close (confirmed bar only) to prevent repainting. Each message includes {{ticker}} and {{close}} placeholders for use in webhook automations or notification routing.
Usage Guide
For intraday futures traders (ES, NQ, DAX): Enable the Daily VWAP Wave and NY VWAP as your primary references. Price reclaiming the NY VWAP after a morning flush is a high-probability mean-reversion setup. Price pushing beyond the Daily Wave High with sustained delta confirms initiative buying.
For swing and multi-day traders : The Rolling VWAP is your core tool. Set the window to 3-5 days and treat it as a dynamic fair value anchor. When price returns to the Rolling VWAP after extended deviation, evaluate whether volume supports continuation or reversal.
For session transition analysis : Enable all three session VWAPs. At the NY open, observe where price is relative to the Asian and London anchors. Acceptance above the London VWAP at NY open is structurally bullish. Rejection and failure below it signals continuation of overnight selling.
For deviation band usage : The ±1σ bands define the statistically normal range for the session. Extended moves to ±2σ with declining volume are classic mean-reversion setups. Moves to ±2σ with expanding volume signal initiative behavior and potential trend continuation. Indicator

Black Tie VWAP MTFVolume-Weighted Average Price (VWAP) on Daily, Weekly, and Monthly anchors, with optional 1σ / 2σ / 3σ deviation bands.
VWAP is the institutional fair-value reference. Algorithmic execution programs (TWAP / VWAP slicing) operate around it; large orders accumulate near it; mean-reverting flows fade extreme deviations from it. Most professional traders treat the VWAP as one of the most important intraday levels.
WHAT IT PLOTS
Daily VWAP, anchored to a configurable session reset.
Weekly VWAP, anchored to the start of the trading week.
Monthly VWAP, anchored to the start of the trading month.
Standard deviation bands at 1σ, 2σ, and 3σ around each VWAP, computed cumulatively from the anchor reset.
USAGE
Use VWAP as a fair-value reference. Price above VWAP indicates net buying pressure since the anchor; price below indicates net selling pressure.
Use the 1σ band as a normal-range boundary. Price tagging the 1σ band and rejecting is a common mean-reversion entry.
Use the 2σ band as an exhaustion zone. Closes beyond 2σ are statistically rare and often precede reversion.
Use the 3σ band as an extreme-outlier marker. Closes beyond 3σ are rare and usually news-driven; trade these with caution.
For intraday trading, the Daily VWAP is the primary reference. The Weekly and Monthly VWAPs serve as higher-timeframe context for swing setups.
ALGORITHM
VWAP is computed as the cumulative volume-weighted average of the source price (default HLC3) since the anchor reset.
Standard deviation is computed as the volume-weighted variance: σ = sqrt(E - E ²), where the expected values are taken cumulatively from the anchor reset. This is mathematically equivalent to the closed-form Welford-style streaming variance and avoids floating-point drift on long sessions.
SETTINGS
Source: defaults to HLC3 (institutional standard). HL2 is faster, OHLC4 is smoother.
Daily Anchor Reset: five modes - Midnight UTC (default, instrument-agnostic), Exchange Default (uses symbol's native session), or one of NY / London / Tokyo session opens.
Each VWAP and band has individual visibility and color controls.
Optional fill between VWAP and 1σ bands for visual emphasis. Indicator

Tactical Deviation MiniTactical Deviation Mini is an overlay indicator that shows up to three independent higher-timeframe VWAPs on one chart—1-hour, 4-hour, and 8-hour—each with 1σ, 2σ, and 3σ standard-deviation bands. By default, only the 4-hour VWAP and its bands are enabled; 1H and 8H are optional toggles. This keeps the chart readable while still letting you stack contexts when you want them.
Why it is useful
Many traders watch where price sits relative to VWAP and to volatility-sized bands across intraday structure. This script puts those references on the same pane as your execution timeframe, so you can compare alignment across 1H / 4H / 8H without switching charts. Optional band fills separate the 1σ–2σ and 2σ–3σ zones. An optional table summarizes sigma distance from VWAP (per enabled timeframe) and RSI(14) on the current bar for quick context.
How it works (concepts)
For each enabled timeframe, the script maintains a running volume-weighted mean of hlc3 and a running volume-weighted second moment so it can derive population-style variance and standard deviation on the fly. When a new bar opens on that higher timeframe, the cumulative sums reset, so each VWAP is anchored to that higher timeframe’s bar sequence (not to the chart’s session template unless your symbol’s bars happen to match that). Band width is standard deviation × your chosen multipliers (defaults 1, 2, 3).
Optional “dynamic” mode
When enabled, the script scales the deviation multipliers using recent volatility (ATR relative to price) so bands can widen in more volatile conditions and narrow in calmer ones. This is a heuristic adjustment, not a guarantee of any particular risk or outcome.
How to use it
Enable the timeframe(s) you want under Timeframe Selection.
Adjust σ multipliers if you want tighter or wider bands.
Toggle Show Deviation Clouds and opacity if you want filled zones.
Use Colors to separate 1H / 4H / 8H visually.
Read the table (if visible) for σ from VWAP and RSI; treat these as context, not instructions.
What this script does not do
It does not plot buy/sell markers, strategy orders, or alerts. It does not rank setups, predict direction, or estimate profitability. Past or hypothetical behavior of VWAP or bands does not imply future results.
Limitations and honesty
VWAP and σ bands depend on volume and bar data available on your symbol and timeframe. On some instruments or sessions, volume or bar construction may differ from what you expect, which affects VWAP and bands. RSI in the table is a standard momentum oscillator shown for reference only.
Disclaimer
This tool is for informational and educational purposes only and is not investment, tax, or trading advice. You are responsible for how you use any charting tool. No warranty is made as to accuracy, fitness, or results. Indicator

Caldera Deviation Cloud [JOAT]Caldera Deviation Cloud
Introduction
The Caldera Deviation Cloud is an open-source statistical deviation band system that fuses anchored VWAP with Z-score adaptive band widths, Keltner ATR blending, and higher-timeframe volatility expansion into a unified probability envelope overlay. Instead of using a single method to calculate band width, CDC triple-blends VWAP standard deviation, statistical standard deviation, and ATR-based Keltner width — whichever produces the widest reading dominates, ensuring the bands never underestimate true market dispersion. The result is a layered cloud with inner (1-sigma, ~68% probability) and outer (2-sigma, ~95% probability) envelopes that adapt to both local and macro volatility conditions.
What makes this indicator distinct from standard Bollinger Bands or VWAP bands is the fusion approach: it does not rely on a single deviation method. It also reverse-engineers historical Z-score reversal points into dynamic "fossil" support and resistance levels — price zones where statistical extremes have historically triggered reversals.
Core Engine: Adaptive Deviation Fusion
The band width calculation blends three independent deviation measurements:
float baseAdapt = na(vwapStdev) or vwapStdev <= 0 ? statDev : math.max(vwapStdev, statDev * 0.5)
float keltBlend = useKelt ? math.max(baseAdapt, keltW * 0.6) : baseAdapt
float adaptDev = keltBlend * macroMult
VWAP Standard Deviation: Derived from the anchored VWAP calculation (session, weekly, monthly, or quarterly reset). This captures volume-weighted price dispersion around the institutional fair value line.
Statistical Standard Deviation: Classic standard deviation of closing prices over a configurable lookback (default 100 bars). This provides a pure statistical measure of price dispersion.
Keltner Thermal Envelope: ATR-based width (EMA of close with ATR multiplier) that captures range-based volatility. When enabled, this prevents the bands from being too narrow during periods where price moves are large but close-to-close deviation is small.
The wider of these three measurements is used as the base deviation, then multiplied by a macro volatility factor derived from the higher timeframe.
Probability Lattice (Z-Score Engine)
The Z-score engine computes how many standard deviations price is from its statistical mean, then smooths the result with VWMA for visual clarity:
Z-Score: (close - SMA) / StdDev, smoothed with VWMA
Mean Reversion Velocity: The rate of change of the Z-score, classified as EXPANDING (moving away from mean), CONTRACTING (returning toward mean), or STALLED
Dynamic State: SHELL BREACH OB/OS (beyond historical reversal averages), ELEVATED/DEPRESSED (beyond 1 sigma), or EQUILIBRIUM (near mean)
Reversal Archaeology (Fossil Levels)
This is one of CDC's most distinctive features. The indicator detects Z-score pivot highs and pivot lows, filters them by a minimum threshold (default 1.5 sigma), and accumulates them into rolling arrays. The average of these historical reversal Z-scores is then reverse-engineered back into price levels:
Fossil Resistance = VWMA(Mean + AvgTopReversalZ * StdDev)
Fossil Support = VWMA(Mean + AvgBotReversalZ * StdDev)
These "fossil levels" represent the price zones where, on average, the market has historically found statistical extremes significant enough to trigger reversals. They shift dynamically as new reversal data accumulates and old data rolls off.
Macro Volatility Lens (HTF Expansion)
When enabled, the indicator fetches standard deviation data from a higher timeframe (default 60-minute) and compares it to its own EMA. When macro volatility exceeds its average, the bands widen proportionally:
macroMult = 1 + htfFactor * max(0, (htfStdev - htfAvgDev) / htfAvgDev)
This prevents the bands from being too tight during periods of elevated macro uncertainty, even if the local timeframe appears calm. The security calls use lookahead=off to prevent repainting.
Visual Elements
Equilibrium Spine: The VWMA-smoothed center line (VWAP or statistical mean), plotted as a prominent purple line representing fair value.
Core Envelope (Inner Bands): 1-sigma bands representing the ~68% probability zone. Color shifts dynamically based on price position within the cloud using color.from_gradient.
Shell Envelope (Outer Bands): 2-sigma bands representing the ~95% probability zone. Price beyond these levels is statistically extreme.
Nebula Gradient: A 10-layer gradient fill system creates a smooth visual transition from the spine outward through the core and shell envelopes. Upper layers use distribution (bearish) tones, lower layers use accumulation (bullish) tones.
Fossil Levels: Cross-style plots marking the reverse-engineered support and resistance from Z-score reversal history.
Signal Architecture
CDC generates four signal types, all confirmed-bar only:
SHELL BREACH: Price exceeds the outer (2-sigma) envelope — a statistically extreme event. Upper breach suggests distribution extreme, lower breach suggests accumulation extreme. Tooltip includes the sigma multiplier and current Z-score.
CORE DRIFT: Price enters the zone between the inner and outer envelopes — elevated deviation but not yet extreme. This serves as an early warning before a potential shell breach.
Command Panel (Dashboard)
A 10-row monospace dashboard displays:
LATTICE: Current smoothed Z-score value
STATE: Statistical classification (Shell Breach OB/OS, Elevated, Depressed, Equilibrium)
REV VEL: Mean reversion velocity direction (Expanding, Contracting, Stalled)
SPINE: Current center line (VWAP/mean) price
APERTURE: Current adaptive deviation width
MACRO: HTF volatility multiplier (1.0x = normal, >1.1x = elevated macro vol)
POSITION: Price location within the cloud (Upper Shell, Upper Core, Neutral, Lower Core, Lower Shell)
FOSSIL R / FOSSIL S: Average Z-score at which historical reversals have occurred (resistance and support)
Input Parameters
Probability Lattice:
Lattice Depth: Z-score lookback window (default 100)
Lattice Damper: VWMA smoothing on raw Z-score (default 14)
Sigma Core: Inner band multiplier, ~68% probability (default 1.0)
Sigma Shell: Outer band multiplier, ~95% probability (default 2.0)
Anchor Nexus:
Volume Epoch: VWAP reset period — Session, Weekly, Monthly, or Quarterly
Keltner Fusion:
Enable Thermal Envelope: Toggle ATR-based width blending (default on)
Thermal EMA / ATR Scale: Keltner channel parameters
Macro Volatility Lens:
Enable Horizon Expansion: Toggle HTF volatility widening (default on)
Horizon Timeframe / Blend Factor: HTF parameters
Reversal Archaeology:
Fossil Depth: Rolling array size for reversal history (default 25)
Fossil Threshold: Minimum Z-score magnitude for valid reversal (default 1.5)
How to Use This Indicator
Use the cloud as a probability envelope — price spending time near the outer shell is statistically unusual and often precedes mean reversion.
Watch SHELL BREACH signals at the outer bands for potential reversal setups, especially when the Reversion Velocity shows CONTRACTING (Z-score returning toward mean).
Fossil levels provide dynamic support/resistance derived from statistical history — they shift as new reversal data accumulates, making them adaptive rather than static.
The MACRO multiplier in the dashboard warns when higher-timeframe volatility is elevated — wider bands during these periods reflect genuine uncertainty, not just noise.
CORE DRIFT signals serve as early warnings — price entering the core-to-shell zone may continue to the shell or reverse. Use them as alerts to pay attention, not as standalone trade signals.
The Equilibrium Spine (center line) acts as a dynamic fair value reference — extended moves away from it tend to revert over time.
Limitations
Statistical bands assume roughly normal price distributions, which markets frequently violate. Fat tails and gap events can exceed even the outer shell without warning.
Z-score mean reversion is a tendency, not a guarantee — price can remain at statistical extremes for extended periods, especially during strong trends.
Fossil levels are based on historical reversal averages and may not predict future reversal points accurately. They provide context, not certainty.
The VWAP anchor resets at each period boundary (session, week, etc.), which can cause discontinuities in the center line and bands.
Higher-timeframe volatility expansion depends on the selected HTF — different choices produce different macro multipliers.
The indicator does not generate directional buy/sell signals — it provides statistical context for your own decision-making.
Originality Statement
This indicator is original in its triple-blend adaptive deviation approach. While VWAP bands, Bollinger Bands, and Keltner Channels are established concepts individually, CDC is justified because:
The triple-blend deviation fusion (VWAP stdev + statistical stdev + Keltner ATR) ensures bands never underestimate dispersion regardless of which volatility measure is dominant.
Reversal Archaeology reverse-engineers Z-score pivot history into dynamic price levels — a technique not found in standard deviation band indicators.
The Macro Volatility Lens integrates higher-timeframe volatility directly into band width calculation, providing macro-aware probability envelopes.
The 10-layer nebula gradient fill creates a visual probability density that communicates statistical significance through color intensity.
Mean Reversion Velocity tracking provides directional context for Z-score movement, helping distinguish between expanding extremes and contracting reversals.
The comprehensive dashboard presents statistical state, reversion dynamics, and fossil levels simultaneously.
Disclaimer
This indicator is provided for educational and informational purposes only. It is not financial advice. Statistical deviation bands describe historical price distribution patterns but do not predict future price movement. Extreme Z-scores do not guarantee reversals. Always use proper risk management and conduct your own analysis before making trading decisions. The author is not responsible for any losses incurred from using this tool.
-Made with passion by officialjackofalltrades
Indicator

Statistical Reversion Engine [JOAT]Statistical Reversion Engine
Introduction
The Statistical Reversion Engine (SRE) is an advanced open-source mean reversion indicator that combines statistical deviation bands, premium/discount zone analysis, DCA level calculation, Z-score measurement, and enhanced reversion probability scoring to identify high-probability mean reversion opportunities. This indicator quantifies price deviation from statistical mean using multiple calculation methods (SMA, EMA, VWAP, HMA) and provides probabilistic assessment of reversion likelihood through multi-factor analysis including deviation magnitude, volatility regime, and historical reversion patterns.
Unlike basic Bollinger Band indicators that simply plot standard deviation bands, SRE employs a sophisticated statistical framework that calculates Z-scores, premium/discount percentages, enhanced reversion probability (incorporating volatility and premium factors), and tracks historical reversion speed to provide traders with quantitative mean reversion intelligence. The indicator also generates DCA (Dollar Cost Averaging) levels with volatility-adjusted spacing for systematic position building.
Why This Indicator Exists
This indicator addresses the challenge of identifying when price has deviated sufficiently from mean to warrant mean reversion trades. Traditional mean reversion indicators lack probabilistic quantification and don't account for volatility regime or historical reversion patterns. SRE systematically reveals:
Multiple Mean Calculations: SMA, EMA, VWAP (session/continuous), HMA for flexible mean definition
Statistical Deviation Bands: 1σ, 2σ, 3σ bands with customizable multipliers
Z-Score Calculation: Quantifies deviation in standard deviation units
Premium/Discount Analysis: Percentage deviation from mean with zone classification
Enhanced Reversion Probability: Multi-factor scoring (Z-score + premium + volatility)
DCA Level Generation: Volatility-adjusted levels for systematic position building
Historical Reversion Tracking: Measures average bars to return to mean after extreme deviation
Each component provides unique intelligence. Mean calculation defines center, deviation bands show extremes, Z-score quantifies magnitude, premium/discount shows percentage, probability scores likelihood, DCA levels provide entry framework, and historical tracking provides context.
Core Components Explained
1. Flexible Mean Calculation System
SRE supports four mean calculation methods:
f_calculate_mean(string type, int length) =>
float result = close
if type == "SMA"
result := ta.sma(close, length)
else if type == "EMA"
result := ta.ema(close, length)
else if type == "VWAP"
result := session_reset ? ta.vwap(hlc3) : ta.vwma(hlc3, length)
else if type == "HMA"
result := ta.hma(close, length)
result
Mean selection impacts reversion behavior:
- SMA: Simple average, slower to respond
- EMA: Exponential weighting, faster response
- VWAP: Volume-weighted, institutional reference
- HMA: Hull Moving Average, smoothest with minimal lag
2. Statistical Deviation Band System
Three deviation bands calculated using standard deviation:
float mean_line = f_calculate_mean(mean_type, mean_length)
float stdev = f_calculate_stdev(close, deviation_period)
float upper_band_1 = mean_line + (stdev * band_multiplier_1) // 1σ
float lower_band_1 = mean_line - (stdev * band_multiplier_1)
float upper_band_2 = mean_line + (stdev * band_multiplier_2) // 2σ
float lower_band_2 = mean_line - (stdev * band_multiplier_2)
float upper_band_3 = mean_line + (stdev * band_multiplier_3) // 3σ
float lower_band_3 = mean_line - (stdev * band_multiplier_3)
Default multipliers: 1.0, 2.0, 3.0 (customizable)
- 1σ: 68% of price action (normal range)
- 2σ: 95% of price action (extended range)
- 3σ: 99.7% of price action (extreme range)
3. Z-Score Calculation & Classification
Z-score quantifies deviation in standard deviation units:
f_calculate_zscore(float price, float mean, float stdev) =>
float zscore = stdev > 0 ? (price - mean) / stdev : 0.0
zscore
float zscore = f_calculate_zscore(close, mean_line, stdev)
Z-score interpretation:
- |Z| < 1.0: Normal deviation (40% reversion probability)
- |Z| 1.0-1.5: Moderate deviation (60% reversion probability)
- |Z| 1.5-2.0: Extended deviation (75% reversion probability)
- |Z| 2.0-2.5: Extreme deviation (85% reversion probability)
- |Z| > 3.0: 3-sigma event (95% reversion probability)
4. Premium/Discount Zone Analysis
Percentage deviation from mean with zone classification:
f_calculate_premium_discount(float price, float mean) =>
float pct = mean > 0 ? ((price - mean) / mean) * 100 : 0.0
pct
float premium_discount_pct = f_calculate_premium_discount(close, mean_line)
string current_zone =
premium_discount_pct >= premium_threshold * 2 ? "Extreme Premium" :
premium_discount_pct >= premium_threshold ? "Premium" :
premium_discount_pct <= discount_threshold * 2 ? "Extreme Discount" :
premium_discount_pct <= discount_threshold ? "Discount" :
"Fair Value"
Zone classification (default thresholds):
- Extreme Premium: >3.0% above mean (strong sell zone)
- Premium: 1.5-3.0% above mean (sell zone)
- Fair Value: -1.5% to +1.5% (neutral zone)
- Discount: -3.0% to -1.5% below mean (buy zone)
- Extreme Discount: <-3.0% below mean (strong buy zone)
5. Enhanced Reversion Probability Scoring
Multi-factor probability calculation:
f_enhanced_reversion_prob(float z, float premium_pct, float vol_rank) =>
float base_prob = f_reversion_probability(z)
// Adjust for premium/discount magnitude
float premium_factor = math.abs(premium_pct) > 3 ? 1.2 :
math.abs(premium_pct) > 2 ? 1.1 :
math.abs(premium_pct) > 1 ? 1.0 : 0.9
// Adjust for volatility (lower vol = higher reversion probability)
float vol_factor = vol_rank < 30 ? 1.2 :
vol_rank < 50 ? 1.1 :
vol_rank < 70 ? 1.0 : 0.85
math.min(base_prob * premium_factor * vol_factor, 99)
Enhanced probability accounts for:
- Base Z-score probability
- Premium/discount magnitude (larger deviation = higher probability)
- Volatility regime (lower volatility = more predictable reversion)
6. Volatility-Adjusted DCA Level Generation
DCA levels automatically adjust spacing based on volatility:
float current_atr = ta.atr(14)
float atr_pct = close > 0 ? (current_atr / close) * 100 : 0
float vol_multiplier = atr_pct > 3 ? 1.5 : atr_pct > 2 ? 1.2 : atr_pct > 1 ? 1.0 : 0.8
for i = 1 to dca_levels
float adjusted_spacing = (dca_spacing * vol_multiplier) / 100
float buy_level = mean_line * (1 - adjusted_spacing * i)
float sell_level = mean_line * (1 + adjusted_spacing * i)
array.push(dca_buy_levels, buy_level)
array.push(dca_sell_levels, sell_level)
Volatility adjustment:
- High vol (ATR% >3): 1.5x spacing (wider levels)
- Elevated vol (ATR% 2-3): 1.2x spacing
- Normal vol (ATR% 1-2): 1.0x spacing (default)
- Low vol (ATR% <1): 0.8x spacing (tighter levels)
7. Historical Reversion Speed Tracking
Measures average bars to return to mean after extreme deviation:
var array reversion_times = array.new_int(0)
var bool tracking_reversion = false
var int reversion_start_bar = 0
if math.abs(zscore) >= 2.5 and not tracking_reversion
tracking_reversion := true
reversion_start_bar := bar_index
if tracking_reversion and math.abs(zscore) < 0.5
int reversion_time = bar_index - reversion_start_bar
array.push(reversion_times, reversion_time)
tracking_reversion := false
float avg_reversion_time = array.size(reversion_times) > 0 ?
array.avg(reversion_times) : na
Average reversion time provides context for expected holding period.
Visual Elements
Mean Line: Electric lime line showing statistical mean
Deviation Bands: 1σ (lime), 2σ (violet), 3σ (deep violet) with gradient fills
Premium/Discount Zones: Background coloring (violet for premium, lime for discount)
DCA Levels: Dotted lines with "B1, B2, B3..." (buy) and "S1, S2, S3..." (sell) labels
Z-Score Label: Current Z-score displayed on price
Gradient Zone Fills: Progressive transparency between bands
Mean Reversion Signals: Triangle markers for strong buy/sell setups
Reversion Probability Heatmap: Background intensity based on enhanced probability
Dashboard: Real-time metrics including zone, P/D%, Z-score, reversion probability, mean value, distance, enhanced probability, deviation percentile, mean trend, nearest DCA, average reversion time, bars since extreme
Input Parameters
Mean Calculation:
Mean Type: SMA, EMA, VWAP, HMA (default: VWAP)
Mean Length: Period for mean calculation (default: 20)
Session Reset (VWAP): Toggle session anchoring (default: true)
Deviation Bands:
Band 1 Multiplier: 1σ multiplier (default: 1.0)
Band 2 Multiplier: 2σ multiplier (default: 2.0)
Band 3 Multiplier: 3σ multiplier (default: 3.0)
Deviation Period: Standard deviation calculation period (default: 20)
Premium/Discount:
Premium Threshold (%): Threshold for premium zone (default: 1.5%)
Discount Threshold (%): Threshold for discount zone (default: -1.5%)
DCA Levels:
Enable DCA Levels: Toggle DCA display (default: true)
Number of DCA Levels: Levels to generate (default: 5)
DCA Spacing (%): Base spacing between levels (default: 1.5%)
Visualization:
Show Deviation Bands: Toggle band display (default: true)
Show Band Fills: Toggle gradient fills (default: true)
Show Premium/Discount Zones: Toggle background coloring (default: true)
Show Z-Score Label: Toggle Z-score display (default: true)
How to Use This Indicator
Step 1: Identify Current Zone
Check dashboard "Zone" row. Extreme Discount = strong buy zone, Extreme Premium = strong sell zone.
Step 2: Assess Z-Score Magnitude
|Z| >2.0 indicates extended deviation. |Z| >3.0 is 3-sigma event (rare, high reversion probability).
Step 3: Check Enhanced Reversion Probability
Dashboard shows enhanced probability accounting for volatility and premium factors. >80% is high probability.
Step 4: Monitor Mean Trend
"Rising" mean suggests uptrend, "Falling" suggests downtrend. Trade with mean trend for higher probability.
Step 5: Use DCA Levels for Entry
Enter positions at DCA levels (B1, B2, B3 for longs; S1, S2, S3 for shorts) to average into position.
Step 6: Wait for Strong Signals
Triangle markers appear when:
- Extreme zone + enhanced probability >80% + band crossover
- These are highest conviction mean reversion setups
Best Practices
Mean reversion works best in ranging markets - avoid strong trends
3-sigma events (|Z| >3.0) have highest reversion probability but occur rarely
Use DCA levels to build positions systematically rather than all-in entries
Enhanced probability >80% indicates high-quality setup
Mean trend provides context - reversion against trend is lower probability
Volatility-adjusted DCA spacing prevents over-concentration in high vol
Average reversion time helps set realistic profit target timeframes
Combine with higher timeframe trend - mean reversion with trend is safer
Deviation percentile >90% indicates extreme deviation
Bars since extreme >50 suggests extended deviation may persist
Indicator Limitations
Mean reversion fails during strong trending markets
3-sigma events can persist longer than expected during major news
DCA levels don't account for fundamental catalysts
Enhanced probability is statistical, not deterministic
Historical reversion time doesn't guarantee future reversion speed
VWAP mean resets daily - may not be appropriate for all timeframes
Standard deviation assumes normal distribution - markets have fat tails
Premium/discount thresholds may need adjustment for different instruments
Technical Implementation
Built with Pine Script v6 using:
Four mean calculation methods (SMA, EMA, VWAP, HMA)
Three-tier deviation band system with customizable multipliers
Z-score calculation with standard deviation
Premium/discount percentage with zone classification
Enhanced reversion probability (Z-score + premium + volatility)
Volatility-adjusted DCA level generation
Historical reversion speed tracking with arrays
Deviation percentile ranking
Mean trend detection (fast vs slow mean)
Gradient zone fills with progressive transparency
Reversion probability heatmap background
Comprehensive dashboard with 12 metrics
The code is fully open-source and can be modified to suit individual trading styles.
Originality Statement
This indicator is original in its comprehensive statistical mean reversion approach. While Bollinger Bands and mean reversion are established concepts, this indicator is justified because:
It combines four mean calculation methods with three-tier deviation bands
Enhanced reversion probability incorporates Z-score, premium magnitude, and volatility regime
Volatility-adjusted DCA level generation adapts to market conditions
Historical reversion speed tracking provides empirical context
Premium/discount zone classification adds percentage-based perspective
Mean trend detection (fast vs slow) provides directional context
Deviation percentile ranking shows historical extremity
Integration of statistical measures (Z-score, stdev, percentile) with practical tools (DCA levels, signals)
Each component contributes unique information: mean defines center, deviation bands show extremes, Z-score quantifies magnitude, premium/discount shows percentage, enhanced probability scores likelihood, DCA levels provide framework, historical tracking provides context, and mean trend shows direction. The indicator's value lies in presenting these complementary perspectives simultaneously with unified statistical framework.
Disclaimer
This indicator is provided for educational and informational purposes only. It is not financial advice. Mean reversion probabilities do not guarantee outcomes. Trading involves substantial risk of loss. Past performance does not guarantee future results. Always use proper risk management and never risk more than you can afford to lose.
-Made with passion by officialjackofalltrades Indicator

Tactical DeviationThis indicator is a mean-reversion system grounded in statistical deviation from the Volume Weighted Average Price (VWAP). Unlike standard Bollinger Bands or static envelopes, the "Tactical Deviation" script integrates Multi-Timeframe Analysis, Dynamic Volatility Scaling, and Market Structure Validation to identify high-probability exhaustion points.
Underlying Concepts & Methodology
The core philosophy of this script is that price tends to revert to its volume-weighted mean after reaching statistical extremes. However, identifying true extremes requires more than just standard deviation. This script employs a three-layer validation filter:
Multi-Timeframe Confluence: The script calculates VWAP and Standard Deviation bands simultaneously for Daily, Weekly, and Monthly timeframes. It allows traders to visualize where short-term price action deviates significantly from longer-term volume trends. A key feature is the "Confluence Mode," which filters out noise by only flagging opportunities where price is overextended on multiple timeframes (e.g., Daily AND Weekly) simultaneously.
Dynamic Volatility Adjustment (Originality): Standard deviation bands are often too static. This script includes a "Dynamic Multiplier" algorithm that ingests Average True Range (ATR) data to adjust the band width.
Logic: Multiplier_Adjusted = Base_Multiplier * (1 + (ATR / Price * 10))
This ensures that during high-volatility events, the bands expand to prevent premature signals, while finding tighter entries during consolidation.
Structural & Volume Validation: Many mean-reversion indicators fail by "catching a falling knife." To mitigate this, this script does not signal solely on band touches. It requires two additional confirmations:
Pivot Confluence: The price must be interacting with a recent Swing Low (for longs) or Swing High (for shorts) specifically calculated within a user-defined lookback period.
Volume Injection: A signal is only valid if volume exceeds its moving average by a defined factor (default 1.5x) or shows significant momentum, confirming institutional participation at the reversal point.
Features & Settings
Deviation Clouds: Visualizes the 1σ-3σ zones with customizable transparency to highlight areas of statistical significance without cluttering the chart.
Signal Filter:
RSI Filter: Optional integration to ensure momentum is also overbought/oversold alongside price deviation.
Pivot Lookback: Adjusts the sensitivity of the market structure detection.
Info Panel: A dashboard displaying the current deviation (in Sigma) for all three monitored timeframes in real-time.
How to Use
This tool is designed for mean reversion trading.
Identify Extremes: Watch for price entering the outer deviation clouds (2σ or 3σ) on the Daily or Weekly VWAP.
Wait for Confirmation: Do not enter blindly on a band touch. Wait for the signal triangle, which confirms that Volume, RSI (if enabled), and Pivot Structure have aligned to suggest a probable reversal.
Risk Management: Use the VWAP itself (the center line) as a dynamic take-profit target, as price statistically gravitates back to this volume-weighted center. Indicator

Indicator

Indicator

Realized Volatility IIR Filters with BandsDISCLAIMER:
The Following indicator/code IS NOT intended to be a formal investment advice or recommendation by the author, nor should be construed as such. Users will be fully responsible by their use regarding their own trading vehicles/assets.
The following indicator was made for NON LUCRATIVE ACTIVITIES and must remain as is following PulseWire's regulations. Use of indicator and their code are published by Invitation Only for work and knowledge sharing. All access granted over it, their use, copy or re-use should mention authorship(s) and origin(s).
WARNING NOTICE!
THE INCLUDED FUNCTION MUST BE CONSIDERED AS TESTING. The models included in the indicator have been taken from open sources on the web and some of them has been modified by the author, problems could occur at diverse data sceneries.
WHAT'S THIS...?
Work derived by previous own research for study:
This is mainly an INFINITE IMPULSE RESPONSE FILTERING INDICATOR , it's purpose is to catch trend given by the nature of lag given by a VOLATILITY ESTIMATION ALGORITHM as it's coefficient. It provides as well an INFINITE IMPULSE RESPONSE DEVIATION FILTER that uses the same coefficients of the main filter to plot deviation bands as an auxiliary tool.
The given Filter based indicator provides my own Multi Volatility-Estimators Function with only 3 models:
ELASTIC VOLUME WEIGHTED VOLATILITY : This is a Modified Daigler & Padungsaksawasdi "Volume Weighted Volatility" as on DOI: 10.1504/IJBAAF.2018.089423 but with Elastic Volume Weighted Moving Average instead of VWAP (intraday) for faster (but inaccurate) calculation. A future version is planned on the way using intra-bar inspection for intraday timeframe as described in original paper.
GARMAN & KLASS / YANG-ZANG EXTENSION : As one of the best range based (OHLC) with open gaps inclusion in a single bar.
PETER MARTIN'S ULCER INDEX : This is a better approach to measure realized volatility than standard deviation of log returns given it's proven convex risk metric for DrawDowns as shown in Chekhlov et al. (2005) . Regarding this particular model, I take a different approach to use it as coefficient feed: Given that the UI only takes in consideration DrawDawns, I code myself the inverse of this to compute Draw-Ups as well and use both of them to filter minimums volatility levels in order to create a SLOW version of the IIR filter, and maximums of both to calculate as FAST variation. This approach can be used as a better proxy instead of any other common moving average given that with NO COMPOUND IN TIME AT ALL (N=1) or only using as long as N=3 bars of compund, the filter can catch a trend easily, making the indicator nearly a NON PARAMETRIC FILTER.
NOTES:
This version DO NOT INCLUDE ALERTS.
This version DO NOT INCLUDE STRATEGY: ALL Feedback welcome.
DERIVED WORK:
Incremental calculation of weighted mean and variance by Tony Finch (fanf2@cam. ac .uk) ([email protected]), 2009.
Volume weighted volatility: empirical evidence for a new realised volatility measure by Chaiyuth Padungsaksawasdi & Robert T. Daigler, 2018.
Basic DSP Tips & Trics by PulseWire user @alexgrover
CHEERS!
@XeL_Arjona 2020. Indicator

Indicator
