OPEN-SOURCE SCRIPT
AMT Order Flow Suite v2.2

AMT Order Flow Suite v2.2 — CVD · Delta · VWAP · Session Levels · Virgin POC
A complete Auction Market Theory order flow indicator built for XAUUSD (Gold), combining Cumulative Volume Delta, per-bar delta, session-anchored VWAP, intraday Point of Control, Value Area levels, Virgin POC detection, and Failed Auction signals — all in one script.
Developed and validated against 1.3 million ticks of raw XAUUSD price data across multiple weeks of live session analysis. Everything you see on the chart is derived from actual volume and delta, not price patterns alone.
WHAT IT SHOWS
Cumulative Volume Delta (CVD)
The core of the indicator. CVD accumulates signed volume throughout each session — positive when buyers are aggressive, negative when sellers dominate. Resets at the start of every new session so you always see the current day's order flow in isolation. An EMA signal line rides on top — when CVD crosses below its signal, bias turns bearish; above it, bullish. The fill colour shifts green/red to make the bias instantly readable.
CVD Divergence Labels
When price makes a new session high but CVD fails to confirm (DIST label) — that is distribution: institutions selling into retail buying. When price makes a new session low but CVD holds up (ABS label) — that is absorption: buyers stepping in as price flushes stops. These are the two highest-conviction signals in the indicator. Both are validated against real tick data.
Per-Bar Delta Histogram
Shows the signed volume of every individual bar — how hard buyers or sellers hit at that exact moment. Weighted by bar body ratio so doji bars don't falsely signal. High-volume bars are flagged with a marker. Absorption bars (high volume + tight range — the classic sign of an iceberg order defending a level) are marked with a diamond.
Session-Anchored VWAP with Standard Deviation Bands
VWAP resets each session and is calculated from the true volume-weighted average price. The ±1σ bands approximate the 70% Value Area — the zone where most of the day's business occurred. The ±2σ bands mark the outer extremes. Price extended beyond ±2σ with declining CVD is one of the strongest mean-reversion signals available.
Intraday POC (Point of Control)
Tracks the price level with the highest volume of the current session in real time. The POC is drawn as a dashed gold line extending right. This is the fair value anchor — price gravitates back to it repeatedly throughout the session and into the next day.
Value Area High (VAH) and Value Area Low (VAL)
Derived from the VWAP standard deviation bands. VAH = VWAP +1σ, VAL = VWAP -1σ. These are the boundaries of accepted value. Price breaking outside them and failing to hold is the definition of a Failed Auction — the primary trade setup this indicator is built around.
Virgin POC Detection
Tracks the POC of the previous two sessions. If price has not returned to a prior session's POC since that session ended, that level is "virgin" — untouched high-volume ground. When price finally reaches it, a circle marker appears on the chart (VP for 1-session-old, VP2 for 2-session-old). Virgin POCs produce the strongest reactions of any level because they contain trapped participants at their cost basis. Lines for VP1 and VP2 are drawn on the chart automatically each session and the live price levels are shown in the info table.
Failed Auction Signals (FA↑ / FA↓)
A Failed Auction occurs when price spikes outside the Value Area then returns back inside, rejecting the breakout. FA↑ (triangle up, below bar) fires when price has recently been below VAL and recovered back into value with positive delta and CVD above its signal line — buyers reclaimed the level. FA↓ (triangle down, above bar) fires when price has been above VAH and falls back with negative delta and CVD below its signal line — sellers rejected the breakout. Both signals are confirmed by CVD direction, not price alone.
Session Backgrounds and Open Labels
Asia (purple), London (gold), and NY (green) session backgrounds so you can instantly see which session produced which price action. LON and NY open labels appear at the exact opening bar of each session.
Live Info Table
Top-right corner dashboard showing: Session CVD, CVD Bias (BULL/BEAR), current bar delta, volume ratio, distance from VWAP, live POC price, VAH and VAL prices, current session name, active signal (if any), and the live levels of VP1 and VP2. Everything you need to read order flow without switching panes.
ALERT CONDITIONS (9 total)
✅ FA Long — Failed Auction long signal fired
✅ FA Short — Failed Auction short signal fired
✅ Bearish CVD Divergence — price new high, CVD not confirming (distribution)
✅ Bullish CVD Divergence — price new low, CVD not confirming (absorption)
✅ Absorption Detected — high volume + tight range at current bar
✅ Virgin POC Touch (1 session) — price reaching yesterday's untouched POC
✅ Virgin POC Touch (2 sessions) — price reaching 2-session-old POC (higher conviction)
✅ London Open — session beginning, watch for stop-hunt then direction
✅ NY Open — key session, trend continuation or reversal hour
SETTINGS
Timezone — set to your broker's chart timezone (default: Europe/London)
London / NY open hours — adjustable so the session labels and alerts fire at the correct time for your data feed
CVD Signal EMA length — controls how responsive the signal line is (default 20)
Volume average length — lookback for the volume ratio and absorption calculations
High-volume threshold — the multiple above average volume that triggers the high-vol flag
Absorption range ratio — how tight a bar's range must be relative to average to qualify as absorption
Level lookback — how many bars the POC tracker uses
All colours — fully customisable: bull, bear, CVD line, POC, VAH, VAL, VWAP, Virgin POC, absorption
HOW TO USE IT
Add to a 1-minute or 5-minute XAUUSD chart. Set your timezone to match your broker's data feed. The CVD pane appears below the chart automatically — if you only want the overlay elements on the main chart, right-click the pane and move or close it.
Each morning before London opens: note the POC, VAH, and VAL from the previous session (visible as dashed lines). Note the VP1 and VP2 levels in the info table — these are your virgin reaction zones for the day.
During London and NY: watch the CVD fill. Green fill above zero with price near VAL = look for FA↑. Red fill below zero with price near VAH = look for FA↓. DIST label at a new price high = distribution, shorts favoured. ABS label at a new price low = absorption, longs favoured.
NOTES
Works on any instrument with volume data but was designed and tested specifically on XAUUSD spot (Gold). The POC and Value Area are approximated using a session-anchored VWAP standard deviation method — this keeps the indicator fast and free of the loop timeout errors that affect bin-based volume profile calculations in Pine Script. For tick-perfect volume profiles, combine with TradingView's built-in Session Volume Profile tool.
Built on Pine Script v6. No repainting. All calculations are bar-confirmed.
A complete Auction Market Theory order flow indicator built for XAUUSD (Gold), combining Cumulative Volume Delta, per-bar delta, session-anchored VWAP, intraday Point of Control, Value Area levels, Virgin POC detection, and Failed Auction signals — all in one script.
Developed and validated against 1.3 million ticks of raw XAUUSD price data across multiple weeks of live session analysis. Everything you see on the chart is derived from actual volume and delta, not price patterns alone.
WHAT IT SHOWS
Cumulative Volume Delta (CVD)
The core of the indicator. CVD accumulates signed volume throughout each session — positive when buyers are aggressive, negative when sellers dominate. Resets at the start of every new session so you always see the current day's order flow in isolation. An EMA signal line rides on top — when CVD crosses below its signal, bias turns bearish; above it, bullish. The fill colour shifts green/red to make the bias instantly readable.
CVD Divergence Labels
When price makes a new session high but CVD fails to confirm (DIST label) — that is distribution: institutions selling into retail buying. When price makes a new session low but CVD holds up (ABS label) — that is absorption: buyers stepping in as price flushes stops. These are the two highest-conviction signals in the indicator. Both are validated against real tick data.
Per-Bar Delta Histogram
Shows the signed volume of every individual bar — how hard buyers or sellers hit at that exact moment. Weighted by bar body ratio so doji bars don't falsely signal. High-volume bars are flagged with a marker. Absorption bars (high volume + tight range — the classic sign of an iceberg order defending a level) are marked with a diamond.
Session-Anchored VWAP with Standard Deviation Bands
VWAP resets each session and is calculated from the true volume-weighted average price. The ±1σ bands approximate the 70% Value Area — the zone where most of the day's business occurred. The ±2σ bands mark the outer extremes. Price extended beyond ±2σ with declining CVD is one of the strongest mean-reversion signals available.
Intraday POC (Point of Control)
Tracks the price level with the highest volume of the current session in real time. The POC is drawn as a dashed gold line extending right. This is the fair value anchor — price gravitates back to it repeatedly throughout the session and into the next day.
Value Area High (VAH) and Value Area Low (VAL)
Derived from the VWAP standard deviation bands. VAH = VWAP +1σ, VAL = VWAP -1σ. These are the boundaries of accepted value. Price breaking outside them and failing to hold is the definition of a Failed Auction — the primary trade setup this indicator is built around.
Virgin POC Detection
Tracks the POC of the previous two sessions. If price has not returned to a prior session's POC since that session ended, that level is "virgin" — untouched high-volume ground. When price finally reaches it, a circle marker appears on the chart (VP for 1-session-old, VP2 for 2-session-old). Virgin POCs produce the strongest reactions of any level because they contain trapped participants at their cost basis. Lines for VP1 and VP2 are drawn on the chart automatically each session and the live price levels are shown in the info table.
Failed Auction Signals (FA↑ / FA↓)
A Failed Auction occurs when price spikes outside the Value Area then returns back inside, rejecting the breakout. FA↑ (triangle up, below bar) fires when price has recently been below VAL and recovered back into value with positive delta and CVD above its signal line — buyers reclaimed the level. FA↓ (triangle down, above bar) fires when price has been above VAH and falls back with negative delta and CVD below its signal line — sellers rejected the breakout. Both signals are confirmed by CVD direction, not price alone.
Session Backgrounds and Open Labels
Asia (purple), London (gold), and NY (green) session backgrounds so you can instantly see which session produced which price action. LON and NY open labels appear at the exact opening bar of each session.
Live Info Table
Top-right corner dashboard showing: Session CVD, CVD Bias (BULL/BEAR), current bar delta, volume ratio, distance from VWAP, live POC price, VAH and VAL prices, current session name, active signal (if any), and the live levels of VP1 and VP2. Everything you need to read order flow without switching panes.
ALERT CONDITIONS (9 total)
✅ FA Long — Failed Auction long signal fired
✅ FA Short — Failed Auction short signal fired
✅ Bearish CVD Divergence — price new high, CVD not confirming (distribution)
✅ Bullish CVD Divergence — price new low, CVD not confirming (absorption)
✅ Absorption Detected — high volume + tight range at current bar
✅ Virgin POC Touch (1 session) — price reaching yesterday's untouched POC
✅ Virgin POC Touch (2 sessions) — price reaching 2-session-old POC (higher conviction)
✅ London Open — session beginning, watch for stop-hunt then direction
✅ NY Open — key session, trend continuation or reversal hour
SETTINGS
Timezone — set to your broker's chart timezone (default: Europe/London)
London / NY open hours — adjustable so the session labels and alerts fire at the correct time for your data feed
CVD Signal EMA length — controls how responsive the signal line is (default 20)
Volume average length — lookback for the volume ratio and absorption calculations
High-volume threshold — the multiple above average volume that triggers the high-vol flag
Absorption range ratio — how tight a bar's range must be relative to average to qualify as absorption
Level lookback — how many bars the POC tracker uses
All colours — fully customisable: bull, bear, CVD line, POC, VAH, VAL, VWAP, Virgin POC, absorption
HOW TO USE IT
Add to a 1-minute or 5-minute XAUUSD chart. Set your timezone to match your broker's data feed. The CVD pane appears below the chart automatically — if you only want the overlay elements on the main chart, right-click the pane and move or close it.
Each morning before London opens: note the POC, VAH, and VAL from the previous session (visible as dashed lines). Note the VP1 and VP2 levels in the info table — these are your virgin reaction zones for the day.
During London and NY: watch the CVD fill. Green fill above zero with price near VAL = look for FA↑. Red fill below zero with price near VAH = look for FA↓. DIST label at a new price high = distribution, shorts favoured. ABS label at a new price low = absorption, longs favoured.
NOTES
Works on any instrument with volume data but was designed and tested specifically on XAUUSD spot (Gold). The POC and Value Area are approximated using a session-anchored VWAP standard deviation method — this keeps the indicator fast and free of the loop timeout errors that affect bin-based volume profile calculations in Pine Script. For tick-perfect volume profiles, combine with TradingView's built-in Session Volume Profile tool.
Built on Pine Script v6. No repainting. All calculations are bar-confirmed.
Script de código aberto
Em verdadeiro espírito do TradingView, o criador deste script o tornou de código aberto, para que os traders possam revisar e verificar sua funcionalidade. Parabéns ao autor! Embora você possa usá-lo gratuitamente, lembre-se de que a republicação do código está sujeita às nossas Regras da Casa.
Welcome to AP Capital – your go-to channel for smart forex trading strategies, live trade breakdowns, and market insights. Learn how to trade with confidence using proven methods like EMA filters, breakout setups, and price action.
Aviso legal
As informações e publicações não se destinam a ser, e não constituem, conselhos ou recomendações financeiras, de investimento, comerciais ou de outro tipo fornecidos ou endossados pela TradingView. Leia mais nos Termos de Uso.
Script de código aberto
Em verdadeiro espírito do TradingView, o criador deste script o tornou de código aberto, para que os traders possam revisar e verificar sua funcionalidade. Parabéns ao autor! Embora você possa usá-lo gratuitamente, lembre-se de que a republicação do código está sujeita às nossas Regras da Casa.
Welcome to AP Capital – your go-to channel for smart forex trading strategies, live trade breakdowns, and market insights. Learn how to trade with confidence using proven methods like EMA filters, breakout setups, and price action.
Aviso legal
As informações e publicações não se destinam a ser, e não constituem, conselhos ou recomendações financeiras, de investimento, comerciais ou de outro tipo fornecidos ou endossados pela TradingView. Leia mais nos Termos de Uso.