OPEN-SOURCE SCRIPT
VWAP (ARCHI)

VWAP Bands — Volume Weighted Average Price with Deviation Bands
Overview
**VWAP Bands** is an advanced VWAP indicator featuring automatic standard deviation bands (±1σ, ±2σ, ±3σ), multiple anchor period options, and fully customizable visuals. Designed for intraday and swing traders who use volume-weighted levels for decision-making.
🔑 Key Features
📐 **Anchored VWAP** — Choose your reset period: Session (default), Week, Month, Quarter, or Year. VWAP resets at the beginning of each period.
📊 **Deviation Bands** — Three levels of standard deviation bands (±1σ, ±2σ, ±3σ) highlight statistical zones of overextension relative to the volume-weighted mean price.
🎨 **Full Customization** — Adjustable colors, line widths, band fills, and edge labels. Toggle each band on/off independently.
📍 **Previous VWAP Close** — Optionally display the closing VWAP level from the previous session as a key reference point.
📈 How to Use
Identifying Value Zones
- Price **at VWAP** = fair value. Institutional traders benchmark execution quality against VWAP.
- Price **above VWAP** = buyers in control, bullish bias.
- Price **below VWAP** = sellers in control, bearish bias.
Mean Reversion Trading
- Price touches **±2σ** = extreme deviation, look for a reversal back to VWAP.
- Price touches **±3σ** = very rare event, high probability of a pullback.
- **±1σ** = normal volatility range, not a standalone signal.
Trend vs Range
- **Trending market**: Price stays on one side of VWAP, bands widen.
- **Ranging market**: Price oscillates around VWAP, bands contract.
### Confluence Trading
Combine VWAP Bands with horizontal support/resistance levels. When a VWAP band aligns with a key level — that's a high-probability zone for entries.
⚙️ Settings
| Parameter | Default | Description |
|-----------|---------|-------------|
| Anchor Period | Session | VWAP reset period (Session/Week/Month/Quarter/Year) |
| Source | hlc3 | Price source (hlc3, close, ohlc4) |
| Band 1 Multiplier | 1.0 | First band (±1σ) |
| Band 2 Multiplier | 2.0 | Second band (±2σ) |
| Band 3 Multiplier | 3.0 | Third band (±3σ) |
| Fill Bands | ✅ | Color fill between bands |
| Show Labels | ✅ | Labels at band edges |
| Prev VWAP Close | ❌ | Previous session VWAP close level |
💡 Tips
1. **Intraday (M5–H1):** Use Anchor = Session. VWAP resets daily.
2. **Swing (H4–D1):** Use Anchor = Week or Month for broader context.
3. **Forex/Gold:** Source `hlc3` provides the closest approximation to tick-based VWAP.
4. **Stocks:** Session VWAP matches the standard institutional benchmark.
⚠️ Note
This indicator calculates VWAP from bar data (OHLCV), not tick data. On lower timeframes (M1–M5), accuracy is near-perfect. On higher timeframes (H4+), slight deviations from tick-based VWAP may occur — this is a fundamental limitation of bar-based calculation.
Overview
**VWAP Bands** is an advanced VWAP indicator featuring automatic standard deviation bands (±1σ, ±2σ, ±3σ), multiple anchor period options, and fully customizable visuals. Designed for intraday and swing traders who use volume-weighted levels for decision-making.
🔑 Key Features
📐 **Anchored VWAP** — Choose your reset period: Session (default), Week, Month, Quarter, or Year. VWAP resets at the beginning of each period.
📊 **Deviation Bands** — Three levels of standard deviation bands (±1σ, ±2σ, ±3σ) highlight statistical zones of overextension relative to the volume-weighted mean price.
🎨 **Full Customization** — Adjustable colors, line widths, band fills, and edge labels. Toggle each band on/off independently.
📍 **Previous VWAP Close** — Optionally display the closing VWAP level from the previous session as a key reference point.
📈 How to Use
Identifying Value Zones
- Price **at VWAP** = fair value. Institutional traders benchmark execution quality against VWAP.
- Price **above VWAP** = buyers in control, bullish bias.
- Price **below VWAP** = sellers in control, bearish bias.
Mean Reversion Trading
- Price touches **±2σ** = extreme deviation, look for a reversal back to VWAP.
- Price touches **±3σ** = very rare event, high probability of a pullback.
- **±1σ** = normal volatility range, not a standalone signal.
Trend vs Range
- **Trending market**: Price stays on one side of VWAP, bands widen.
- **Ranging market**: Price oscillates around VWAP, bands contract.
### Confluence Trading
Combine VWAP Bands with horizontal support/resistance levels. When a VWAP band aligns with a key level — that's a high-probability zone for entries.
⚙️ Settings
| Parameter | Default | Description |
|-----------|---------|-------------|
| Anchor Period | Session | VWAP reset period (Session/Week/Month/Quarter/Year) |
| Source | hlc3 | Price source (hlc3, close, ohlc4) |
| Band 1 Multiplier | 1.0 | First band (±1σ) |
| Band 2 Multiplier | 2.0 | Second band (±2σ) |
| Band 3 Multiplier | 3.0 | Third band (±3σ) |
| Fill Bands | ✅ | Color fill between bands |
| Show Labels | ✅ | Labels at band edges |
| Prev VWAP Close | ❌ | Previous session VWAP close level |
💡 Tips
1. **Intraday (M5–H1):** Use Anchor = Session. VWAP resets daily.
2. **Swing (H4–D1):** Use Anchor = Week or Month for broader context.
3. **Forex/Gold:** Source `hlc3` provides the closest approximation to tick-based VWAP.
4. **Stocks:** Session VWAP matches the standard institutional benchmark.
⚠️ Note
This indicator calculates VWAP from bar data (OHLCV), not tick data. On lower timeframes (M1–M5), accuracy is near-perfect. On higher timeframes (H4+), slight deviations from tick-based VWAP may occur — this is a fundamental limitation of bar-based calculation.
開源腳本
秉持TradingView一貫精神,這個腳本的創作者將其設為開源,以便交易者檢視並驗證其功能。向作者致敬!您可以免費使用此腳本,但請注意,重新發佈代碼需遵守我們的社群規範。
免責聲明
這些資訊和出版物並非旨在提供,也不構成TradingView提供或認可的任何形式的財務、投資、交易或其他類型的建議或推薦。請閱讀使用條款以了解更多資訊。
開源腳本
秉持TradingView一貫精神,這個腳本的創作者將其設為開源,以便交易者檢視並驗證其功能。向作者致敬!您可以免費使用此腳本,但請注意,重新發佈代碼需遵守我們的社群規範。
免責聲明
這些資訊和出版物並非旨在提供,也不構成TradingView提供或認可的任何形式的財務、投資、交易或其他類型的建議或推薦。請閱讀使用條款以了解更多資訊。