Post-Absorption VWAP Reversal Engine V1.6
Post-Absorption VWAP Reversal Strategy
This strategy is a TradingView/Pine backtesting and paper-trading model built around a specific intraday market-structure idea:
High volume + low price movement + VWAP location = possible absorption and VWAP mean reversion.
The goal is to detect candles where a lot of volume trades, but price does not move very far. This can suggest that aggressive buyers or sellers were absorbed by passive liquidity.
When this happens away from session VWAP, the strategy looks for a possible fade back toward VWAP.
This is not a simple VWAP touch strategy. It does not buy or sell only because price is above or below VWAP. It first looks for an “effort versus result” imbalance.
High effort = unusually high volume.
Low result = small candle displacement compared with ATR.
VWAP location = where the absorption happened relative to session fair value.
Core Logic
The strategy looks for absorption bars using two main conditions:
1. Volume percentile is high.
Example: volume is in the top 90% or 95% of recent bars.
2. Candle displacement is low.
Example: candle body size divided by ATR is below a configured threshold such as 0.30.
When both conditions happen together, the script marks the candle as a possible absorption event.
VWAP Location Logic
If absorption happens above VWAP:
Buyers may be getting absorbed.
This may create a short-side fade candidate back toward VWAP.
If absorption happens below VWAP:
Sellers may be getting absorbed.
This may create a long-side fade candidate back toward VWAP.
If absorption happens near VWAP:
The signal is usually less directional and may be treated as ambiguous.
Plain-English Example
If price is above VWAP and a high-volume candle fails to push much higher, the strategy asks:
“Did buyers try to push price up but get absorbed?”
If yes, the model may look for a short-side fade back toward VWAP.
If price is below VWAP and a high-volume candle fails to push much lower, the strategy asks:
“Did sellers try to push price down but get absorbed?”
If yes, the model may look for a long-side fade back toward VWAP.
Main Features
- Session VWAP calculation
- Volume percentile filter
- Displacement / ATR filter
- Above-VWAP and below-VWAP absorption classification
- Optional long-only, short-only, or both-side mode
- Optional paper strategy entries
- Multiple exit modes
- Next-bar entry option
- Same-bar exit protection
- Cleaner chart display
- TradingView Strategy Tester support
- Webhook-compatible alert messages for paper/sim testing
Why This Is Different From Basic Indicators
Many indicators use RSI, MACD, raw volume spikes, or simple VWAP crosses.
This strategy is different because it combines:
- volume context,
- candle displacement,
- ATR normalization,
- VWAP location,
- session structure,
- and paper-trading execution logic.
The strategy is trying to model a specific market behavior:
A large amount of trading happened, but price failed to move. That failure may signal absorption, and price may later revert toward VWAP.
Best Use Case
This script is designed for intraday futures testing, especially liquid markets such as ES, YM, MES, and MYM.
It can be tested on short intraday timeframes such as 3-minute, 5-minute, and 15-minute charts. It work considerably on 3minutes.
The strategy should be evaluated using:
- Net profit
- Profit factor
- Win rate
- Maximum drawdown
- Long-side performance
- Short-side performance
- Timeframe behavior
- Session behavior
- Forward paper-trading results
Important Status
This is a backtesting and paper-trading strategy candidate.
It is not a guaranteed profitable system.
It is not financial advice.
It is not fully live-validated.
Recent ES and YM testing has shown promising behavior in some windows and timeframes, but performance can change by symbol, timeframe, session, risk settings, and market regime.
Known Risks
Backtest fills can differ from live fills.
TradingView Strategy Tester assumptions may not match real broker execution.
Some settings may perform well over short periods but fail over longer periods.
A strategy can show good profit factor and still have drawdown that is too high for prop-firm rules.
Webhook execution requires separate safeguards, broker symbol mapping, duplicate-alert protection, and account-level risk controls.
This strategy should be paper-tested before any real-money use.
Suggested Testing Process
1. Start with paper trading only.
2. Test one symbol at a time.
3. Compare 3-minute, 5-minute, and 15-minute charts. 3minutes well considerably well on YM/ES
4. Track profit factor, drawdown, win rate, and number of trades.
5. Separate long-side and short-side performance.
6. Do not rely on one short backtest window.
7. Forward-test before considering any live execution.
Final Note
The purpose of this script is to provide a structured way to test VWAP-based absorption reversal behavior.
It is a research-backed paper-trading framework, not a promise of future performance.
Use risk management and test carefully. Strategie

[Tiestobob] Previous Day and Overnight Highs/Lows** Previous Day and Overnight Highs/Lows**
This indicator plots two of the most widely watched price levels used by intraday traders — the **Previous Day High/Low (PDH/PDL)** and the **Overnight High/Low (ONH/ONL)** — directly on your chart, automatically adjusted for New York time (EST/EDT).
---
**📌 What It Does**
- **Previous Day H/L** — Draws dashed white lines at the prior trading day's high and low (6:00 PM – 4:00 PM ET session)
- **Overnight H/L** — Draws dotted green/red lines marking the high and low of the overnight session (6:00 PM – 9:30 AM ET), a key range watched by futures and forex traders before the regular market open
- Optional **H/L labels** (PDH, PDL, ONH, ONL) appear at the close of each session
- Lines can be **extended to the right** so levels remain visible throughout the trading day
---
**⚙️ Settings**
| Option | Description |
|---|---|
| Select what to plot | Choose between Previous Day H/L or Overnight H/L |
| Show H/L Labels | Toggle end-of-session labels on/off |
| Line Width | Adjust line thickness (1–3) |
| Extend Lines Right | Keep levels visible after the session ends |
---
**📋 Notes**
- All sessions are calculated using the **America/New_York** timezone, automatically accounting for daylight saving time
- Best used on intraday timeframes (1m, 5m, 15m, 1H)
- Pairs well with volume profile, VWAP, and market structure tools
---
*These levels are commonly used as areas of interest for reversals, breakouts, and liquidity sweeps. Use them as context — not signals.* Indikator

Indikator

Indikator

Internal & External MSSHere is a quick breakdown of what it does and its key features:
Dual Tracking (Internal vs. External): It calculates two different sets of market swings simultaneously. It tracks smaller, short-term price movements (Internal MSS) and larger, structural price movements (External MSS).
Overlap Prevention: To keep your chart clean, if a short-term Internal shift and a long-term External shift occur at the exact same price level, the script is programmed to only draw the more significant External level.
Wick vs. Body Calculation: You can toggle the settings to define market structure using either the extreme highs/lows of the candle wicks, or the real bodies (open/close) of the candles.
Smart Label Placement: Breakout lines are drawn horizontally from the broken swing point, and text labels (like "E-MSS" or "i-MSS") automatically float above or below the lines so they don't collide with the drawings.
Fully Customizable Visuals: Through the settings menu, you can easily change the line colors, thickness, dashed/solid styles, and the exact text used for the labels without needing to edit the code again. Indikator

Colored Volume Bars [LazyBear] v6 [Remake J. Lubin 5/2026]A modernized Pine Script v6 rebuild of LazyBear's classic *Colored Volume Bars* indicator, with new themes, a multi-type volume moving average, and built-in alerts.
The script colors each volume bar based on the relationship between the **current bar and a lookback bar** — comparing both price direction and volume change — to make accumulation, distribution, exhaustion, and stealth moves visually obvious at a glance.
**Color logic**
- **Price Up + Volume Up** → strong bullish (real buying pressure)
- **Price Up + Volume Down** → weak bullish (rally on thin volume)
- **Price Down + Volume Up** → strong bearish (active selling)
- **Price Down + Volume Down** → weak bearish (fading sellers)
- **Neutral** → no clear direction
**Features**
- Pine Script v6, lightweight and fast
- 4 visual themes + fully customizable colors:
- Classic LazyBear
- Futuristic Neon
- Modern Professional
- Minimal Clean
- Custom
- Optional volume moving average with **5 MA types**: SMA, EMA, RMA, WMA, TEMA (true triple-EMA formula)
- Adjustable lookback, bar transparency, and MA line width
- Built-in alerts:
- Bullish confirmation (price up + volume up)
- Bearish confirmation (price down + volume up)
- Volume expansion
- Volume contraction
**How to use**
Add it to any chart and any timeframe. Use it as a confirmation tool alongside price action, trend, or breakout strategies — green/strong-color bars confirm conviction behind a move; weak-color bars warn that momentum may be fading.
**Credits**
Original concept by **LazyBear**. This version is a full v6 rewrite with theming, MA flexibility, and alerts added — original color logic preserved exactly under the "Classic LazyBear" theme.
Indikator

Adaptive Trend Intelligence + SMC + RVOL + ML - FloAlgoThis indicator combines an Adaptive SuperTrend with Smart Money Concepts (SMC) market structure, Relative Volume (RVOL) filtering, and an online Machine Learning model to produce high-confidence trend-following signals.
How It Works
Adaptive SuperTrend — A SuperTrend band whose ATR multiplier scales automatically based on the short/long volatility ratio. In quiet markets the band tightens; in expansions it widens. An optional noise filter requires price to hold on the new side for N bars before a flip is accepted, eliminating whipsaws.
SMC Market Structure Engine — Uses a Stochastic Momentum Oscillator to detect overbought/oversold pivots and build an alternating High/Low swing chain. From those swings it tracks Dow-Theory labels (HH, HL, LH, LL), draws a zigzag, plots S/R zones, and detects BOS (Break of Structure) when price closes beyond the previous major swing confirming trend continuation, and CHoCH (Change of Character) when price closes beyond the prior opposing major swing signaling a trend flip. Both events require an established trend direction and fire only against the correct structural level, preventing false signals on internal corrections.
RVOL Filter — Computes directional buy/sell volume from candle structure and ranks it against a rolling percentile. Signals are suppressed unless the directional volume percentile clears a configurable threshold, keeping entries to high-participation moves only.
Online ML Model — A logistic regression model with L2 regularisation trained incrementally on every confirmed SuperTrend flip. It learns 17 features per signal including candle shape, volume, momentum, ATR slope, RSI, Bollinger position, RVOL, and SMC bias, then resolves each trade when the next flip occurs. Probability is displayed in the info table and can gate signals via a minimum confidence threshold.
Visual Elements
SuperTrend line with bull/bear fill
▲ / ▼ signal arrows and labels
BOS / CHoCH labels at structure breaks
HH / HL / LH / LL Dow labels at each pivot
Zigzag lines connecting momentum pivots
S/R zone boxes, colour-coded and fading on break
Info table showing Signal, Trend, ML Confidence, RVOL, Momentum, Volatility, Quality, MS Bias, and last Structure event
Key Settings
ATR Length — lookback for ATR calculation
ATR Multiplier — base band width
Adaptive Multiplier — auto-scales multiplier with volatility ratio
Noise Filter (bars) — bars price must hold before flip is confirmed
RVOL Lookback — rolling window for volume percentile ranking
RVOL Min Percentile % — minimum directional volume percentile to allow a signal
Min ML Probability % — minimum ML model confidence to allow a signal
Stochastic Length — sensitivity of the momentum pivot oscillator
Overbought / Oversold — stochastic zone thresholds for pivot detection
Filter Signals by MS — gate signals to align with SMC trend direction
Max S/R Zones per Side — maximum supply/demand boxes kept on chart
Indikator

Sector Breakout + Golden Setup ScannerVisual Meaning Rarity Light blue background BASING — consolidation forming Common🟠 Diamond "ER" EARLY ROTATION — RS strong, price still in base Uncommon🟢 Triangle "BO" EMERGING BREAKOUT — pivot break + RS + volume Uncommon🟢 Large triangle "CBO"CONFIRMED BREAKOUT — full Stage-2 break Rare🟡 Yellow background + huge "GOLDEN SETUP" label All 10 strict criteria met Very rare🟠 Small "8+" triangle Near-Golden (8 of 10) — watchlist trigger Uncommon
The key insight: GOLDEN SETUP is a special case of EARLY ROTATION. It fires only when the early signal is also passing all 10 strict tests. Most Early Rotations won't qualify as Golden Setups — that's the point.
The Unified Label Shows Everything
STAGE: EARLY ROTATION (or GOLDEN SETUP if all 10 pass)
Score: 72/100 Pass: 9/10
==========================
TIER 1 - RS LEADERSHIP
RS at New High
RS Slope 8.45% (need >5%)
Mansfield 4.21 (need >0)
Accel 1M=4.5% / 3M=18.2% <- this is why it's not Golden yet
==========================
TIER 2 - BASE QUALITY
Valid Base Structure
ATR Contracting
Base Range 11.5% (need 8-15%)
Dist Pivot -1.20% (need -2 to 0%)
==========================
TIER 3 - CONFIRMATION
Volume 1.82x (need >1.5x)
Stage-2 Trend
Score >= 65
==========================
Pivot: 23,450.00
Stop: 21,200.00
VCP Pattern: YES
Color of the label box itself tells you status at a glance:
Yellow box = Golden Setup ACTIVE
Green box = Confirmed Breakout
Lime box = Emerging Breakout
Orange box = Early Rotation or Near-Golden (8+/10)
Dark box = Waiting / Basing / Trending
How to Read It in Practice
Scenario A — Stage shows "EARLY ROTATION" but Golden = 6/10:
Setup is forming but missing key criteria. Watchlist only — don't size in yet.
Scenario B — Stage shows "EARLY ROTATION" + Golden = 9/10:
Almost there. Identify the one missing criterion (label will tell you). When it flips, this is your high-conviction entry.
Scenario C — Stage shows "GOLDEN SETUP" (Pass 10/10):
This is the trade. Yellow background, huge label on chart, alert fires. Score will be 70+. Take the trade with stops at the Support level shown.
Scenario D — Stage shows "EMERGING BO" but Golden was never triggered:
The breakout fired without the strict pre-conditions. Lower conviction — could work but no Golden-grade signal beforehand.
Scenario E — Stage shows "CONFIRMED BO" + Golden was triggered earlier:
You missed the early entry. The Confirmed signal here is "extension" territory — still valid but lower R:R.
Alert Strategy
Set these alerts in priority order:
GOLDEN SETUP TRIGGERED — highest priority, fires rarely
Near Golden Setup (8+/10) — gives you early heads-up
EARLY ROTATION — catches setups that may not become Golden but still tradeable
CONFIRMED BREAKOUT — entry confirmation if you missed the early signal
Quick Reminders
Sector indices (CNXFMCG, CNXPHARMA, etc.): Turn OFF "Require Volume Surge" — no volume data
ETFs and individual stocks: Leave volume check ON
Weekly timeframe is the sweet spot for this framework — daily produces too many noisy signals; monthly too few
The Golden Setup is designed to be rare (maybe 1-2 sectors at a time across the entire NSE universe). If you see it firing on many sectors simultaneously, the broader market is in strong accumulation — itself a useful signal.
This is now your complete tactical scanner: stage detection for context, Golden Setup for conviction trades, all on one chart with no toggling between scripts.
Indikator

Indikator

Indikator

Indikator

Indikator

Indikator

Breakout and Retest Signals - FloAlgoThis indicator detects breakout and retest signals by identifying key pivot zones and validating price rejection through wick sweeps and volume analysis.
How It Works
The script operates in three stages:
Pivot Zone Detection — Identifies swing highs and lows, then constructs zones anchored to the candle body and wick that formed the pivot. Demand zones span from body top down to wick low; supply zones span from wick high down to body bottom.
Rejection Validation — Confirms a valid signal when price sweeps beyond the zone extreme (wick tip) and closes back through the zone body, indicating institutional liquidity capture.
Volume Confirmation — Uses lower timeframe volume delta and buy/sell ratio to validate signal strength, filtering weak rejections with insufficient conviction.
Key Advantages
No Repaint — Single-period pivot detection ensures signals fire on confirmed historical bars, eliminating repaint delay between alert and visual.
Fixed Width Zones — Zones do not grow indefinitely; they are drawn with fixed horizontal width and trimmed only on signal, keeping charts clean.
Range-Based Overlap Guard — Demand and supply zones cannot overlap; range-based checking prevents conflicting zones from occupying the same price area.
Professional Visuals — No text labels or arrow clutter; only shaded zones and volume ratio splits for clean, professional appearance.
Accurate Zone Geometry — Zones anchored to actual candle body and wick formations, not flat ATR bands.
Auto-Cleanup — Zones are automatically removed one bar after signal or on expiry, preventing chart clutter.
Seconds Chart Support — Volume timeframe input guarded to prevent errors on sub-minute charts.
No Signal Conflicts — Removed confirmation divisor that caused opposing signals on the same bar.
Zone Lifecycle
Unlike traditional indicators that grow zones indefinitely, this script uses a fixed-width approach:
Zones are drawn from the pivot candle to a fixed future bar (born + maxLife)
Upon signal, the zone right edge is trimmed to the signal bar
The zone remains visible for one bar after the signal, then is automatically removed
Expired zones without signals are cleanly purged to prevent chart clutter
Visual Elements
Shaded boxes marking demand (green) and supply (red) pivot zones
Volume ratio split boxes within zones showing buy/sell pressure balance
Dashed target projection lines from signal bars
Zone borders fade and thin out after signal confirmation
Key Settings
Swing Length — Sensitivity of pivot high/low detection
Max Bars Active — Fixed horizontal width of zones in bars
Min Bars Between — Minimum bars between consecutive signals
Max Zones Per Side — Maximum active zones per direction
Volume TF — Frame for volume delta analysis
Show Ratio Split — Display buy/sell volume ratio inside zones
Show TP Line — Display target projection lines
Indikator

Indikator

Indikator

Indikator

Indikator

Indikator

Open Interest Suite [QuantAlgo]🟢 Overview
The Open Interest (OI) Suite is a comprehensive OI visualization and analysis tool built specifically for crypto perpetual futures traders. It reads open interest data directly from TradingView-supported exchanges, giving you a way to monitor how many active contracts are currently open in the market. Whether you are tracking a single exchange or aggregating OI across venues like Binance, Bybit, Bitget, Coinbase, Kraken, HTX, BitMEX, and OKX, this indicator is one of the most powerful contextual tools available, allowing traders to quickly gauge overall perpetual futures market positioning.
🟢 What is Open Interest?
Open interest (OI) is the total number of live contracts between buyers and sellers at any given moment. Every long is matched to a short at a 1:1 ratio, so OI gives you a strong sense of how much capital and how many positions are currently committed to the market. Rising OI suggests new money and new positions are entering. Falling OI suggests positions are being closed or liquidated. When combined with price action, OI becomes one of the most valuable lenses available for understanding what is likely happening beneath the surface of price movement in perpetual markets.
🟢 How It Works
The indicator operates in two distinct modes. In Single (Chart) mode, it automatically reads open interest from whichever supported exchange and perpetual contract you are currently viewing, requiring no manual configuration. In Aggregated mode, it fetches OI from some of the highest-volume exchanges in crypto, for example, Binance, Bybit, Bitget, Coinbase, Kraken, HTX, BitMEX, and OKX, combines them into a single composite total, and gives you a cross-market view of positioning that no individual exchange feed can provide on its own. For each exchange in Aggregated mode, OI is fetched across both USDT and USDC perpetual pairs where applicable, then converted to a unified measure before summing. More exchanges will be added as their data becomes available on TradingView.
The Measure setting controls how OI values are expressed. In Coins mode, values are kept in their native unit, which may be more useful when you want to observe raw contract volume independent of price fluctuations. In Dollars mode, coin quantities are multiplied by the current bar price to convert values into USD, which is the standard way most traders and data providers report OI and tends to make cross-asset comparisons more intuitive. For exchanges that report natively in USD, the conversion is handled in reverse when Coins mode is active.
🟢 Key Features
▶ View Modes
The indicator offers four ways to visualize OI, each suited to a different analytical purpose.
1. Candles: Renders OI as full OHLC candlesticks, displaying open, high, low, and close OI for every bar. This is the richest view for studying OI structure, trends, compression, and expansion over time. You can watch OI build or unwind bar by bar similarly to how you read price action, which may help with spotting periods of aggressive position-building or rapid deleverage.
2. Lines: Renders OI as a single continuous line using the close value of each bar. Cleaner and less visually demanding than candles, this mode works well for maintaining OI context alongside other indicators without crowding the chart.
3. Change: Displays the bar-over-bar absolute difference in OI as a histogram. Positive bars indicate net new positions were likely opened. Negative bars suggest net positions were closed or liquidated. This mode can help identify the bars where positioning shifted most dramatically, which often corresponds to high-conviction entries, forced liquidations, or possible trend exhaustion.
4. Change (%): The same histogram expressed as a percentage of the prior bar OI value. This normalises the signal across different asset sizes and OI magnitudes, which could make it easier to compare positioning dynamics between a large-cap asset and a smaller altcoin.
▶ Aggregated Mode and Exchange Selection
In Aggregated mode, each of the eight supported exchanges can be toggled on or off independently. This flexibility allows several useful configurations beyond a simple total. You can enable only one exchange to track that specific venue regardless of which chart you are currently viewing. You can also add the indicator to your layout multiple times with a different single exchange selected each time, letting you compare individual exchange OI side by side on the same chart.
▶ Color Presets
Five built-in color presets (Classic, Aqua, Cosmic, Cyber, Neon) allow you to match the indicator's appearance to your chart setup with a single click. A Custom preset exposes individual color pickers for bull, bear, and line colors, giving full control over every visual element including candle bodies, wicks, borders, histogram columns, and the line overlay.
▶ Unsupported Exchange Warning
When Single (Chart) mode is active and the current exchange does not provide open interest data on TradingView, the indicator displays a warning label on the chart identifying the unsupported exchange and listing supported alternatives.
🟢 Price + OI Interpretation
Reading OI in isolation is only part of the picture. More meaningful analysis tends to come from combining OI direction with price action and, where available, volume data, along with other trend-following or mean-reversion indicators.
Examples:
1. Price Up + OI Up: New capital is likely entering on the long side. This could indicate bullish trend continuation, with fresh positioning supporting the move rather than just short covering. The stronger the OI growth relative to price movement, the higher the probability that the trend has genuine participation behind it.
2. Price Down + OI Up: New shorts are probably being added aggressively. Bearish momentum may be building through fresh positioning, which tends to be a more sustained signal than a move driven purely by long liquidations.
3. Price Down + OI Down: Longs are likely closing or being liquidated. The selling pressure in this scenario is coming from position unwinds rather than new short entries, which could sometimes suggest exhaustion near a local low rather than fresh trend initiation.
4. Price Up + OI Down: Shorts are probably closing or being squeezed out. This is the likely mechanics of a short squeeze: buyers overwhelm sellers, underwater shorts cover, and the resulting buy pressure may accelerate the move higher. This pattern tends to produce some of the fastest and sharpest price moves seen in crypto perpetual markets.
It is worth noting that for every short there is a long. When OI increases during a downtrend, it does not necessarily mean only shorts are entering. Longs are participating too, often more passively through limit orders. Cumulative Volume Delta (CVD) can help distinguish which side is more likely driving the flow, since it measures aggressive buying versus aggressive selling pressure within each bar.
🟢 Important Notes
1. This indicator is designed exclusively for crypto perpetual futures and will not produce output on spot tickers, equity symbols, or any instrument without a corresponding OI feed on TradingView. In Single (Chart) mode, if the exchange you are viewing is not among the currently supported venues (Binance, Bybit, Bitget, Coinbase, Kraken, HTX, BitMEX, and OKX), the indicator will display a warning and produce no data. Switching to a supported exchange will restore functionality. More exchanges will be added as their data becomes available on TradingView.
2. OI is most useful as a context layer rather than a standalone signal. Using it alongside price structure, volume, and order flow analysis may help you assess whether a move is likely backed by new positioning or driven by position unwinds. That distinction could have meaningful implications for how far a move extends and how quickly it might reverse. Indikator

Indikator

Carry Cost MonitorThe bill you did not expect
You run a Swiss franc account. You trade Micro E-mini S&P 500 futures because the US equity market is where the liquidity is. One quarter later your broker sends a statement and there it is: CHF 1,600 in debit interest . Nobody warned you. The contract you traded settles in US dollars. Your account holds Swiss francs. Interactive Brokers lent you the dollars, charged you the USD overnight rate plus 1.5% markup on every dollar for every day you held the position. Meanwhile your Swiss franc cash earned close to nothing because the SNB policy rate sits well below the Fed Funds rate. The gap between those two rates, accumulated silently over months, is the carry cost that drained your account.
This is not a rare edge case. Any trader whose account currency differs from the instrument currency faces the same mechanic. A European trading US equities, a Japanese investor buying Australian bonds, a Canadian holding FTSE futures. The cost is real, it compounds daily, and most platforms do not surface it until the quarterly statement arrives.
The Carry Cost Monitor exists to make this cost visible before it accumulates . It shows the yield differential between your account currency and the instrument currency in real time, estimates the financing cost or income over any horizon you choose, and lets you compare all major currencies side by side so you can make informed decisions about where and what you trade.
The indicator applied to a US dollar denominated chart with a CHF base account. The dashboard in the top right shows the carry spread, percentile rank, estimated annual cost, and break-even return. Below, the comparison table lists all available currencies sorted by carry cost.
What carry costs actually are
When you hold an instrument denominated in a foreign currency, your broker creates a loan in that currency to settle the trade. You owe interest on the borrowed amount and may earn interest on your deposited base currency. The net cost is the difference between those two rates plus whatever the broker charges on top.
The indicator formalizes this as:
Carry Spread (%) = Y_instrument - Y_account
where Y is the sovereign yield for the selected maturity. A positive spread means you borrow a currency that yields more than yours. You pay. A negative spread means the borrowed currency yields less than your base. You earn.
The gross carry rate adds the broker fee:
Gross Carry (%) = Carry Spread + Broker Markup
Interactive Brokers structures this markup in tiers (Interactive Brokers, 2024):
Balance 0 to 100,000: benchmark + 1.50%
Balance 100,000 to 1M: benchmark + 0.50%
Balance above 1M: benchmark + 0.30%
The estimated cost over a chosen horizon follows standard money market convention, adjusted for each currency's day count basis (Stigum and Crescenzi, 2007):
Cost = Nominal * (Gross Carry / 100) * (Days / Day Count Basis)
Day Count Basis is 360 for USD, EUR, CHF, JPY, and SEK (ACT/360), and 365 for GBP, CAD, AUD, and NZD (ACT/365). These match the interbank settlement rules in the ISDA day count fraction definitions (ISDA, 2006).
Finally, the break-even tells you how much your instrument must move to cover the carry drag:
Break-Even (%) = |Gross Carry| * (Days / 365)
This is the minimum performance needed to not lose money purely from financing.
Where the data comes from
The indicator pulls sovereign bond yields for 9 currencies across two maturities (2-year and 10-year), totaling 18 external data requests. The symbols follow TradingView's TVC convention:
USD: US02Y / US10Y EUR: DE02Y / DE10Y (Germany as eurozone proxy)
CHF: CH02Y / CH10Y GBP: GB02Y / GB10Y
JPY: JP02Y / JP10Y CAD: CA02Y / CA10Y
AUD: AU02Y / AU10Y NZD: NZ02Y / NZ10Y
SEK: SE02Y / SE10Y
The 2-year yield is the default because it sits closest to actual overnight funding rates. The correlation between 2-year sovereign yields and their respective benchmarks (SOFR for USD, SARON for CHF, ESTR for EUR) typically exceeds 0.85 over rolling 1-year windows, with average deviations of 20 to 50 basis points (Ilmanen, 2011). That deviation is smaller than the broker markup itself, making sovereign yields a practical proxy.
Why not use the overnight rates directly? Most are only available at monthly frequency through FRED on TradingView, with shorter history. Sovereign yields update daily with 10+ years of data. The trade-off is slight imprecision for much better coverage and responsiveness.
The instrument currency is detected automatically through the built-in syminfo.currency variable. When it matches your account currency, the indicator reports zero cost because no foreign exchange borrowing occurs. Currencies whose yield data returns nothing on TradingView are hidden from the chart and dashboard automatically.
The settings panel showing the Carry Model inputs. Account Currency is set to CHF, Yield Maturity to 2Y, Position Size to 100,000, and the broker tier to 0-100k. These four settings control the entire cost calculation.
Reading the carry lines
The main panel draws up to 8 spread lines, one per foreign currency relative to your account currency.
The zero line is the boundary. Everything above it costs you money. Everything below it earns you money. The further a line sits from zero, the larger the financing effect.
For the active instrument pair, a 1-sigma band (252-day rolling mean plus/minus one standard deviation) wraps around the spread. When the current value breaks outside this band, the carry environment is statistically unusual compared to its own recent history. That might mean a central bank shifted rates, or term spreads moved.
Each currency has its own color, chosen to stay distinguishable even under the most common forms of colorblindness:
USD: blue EUR: amber CHF: red GBP: purple
JPY: emerald CAD: orange AUD: cyan NZD: lime
SEK: fuchsia
The historical view with all currency lines visible. Each colored line represents one currency's carry spread against the selected base. Crossing the zero line marks a shift from paying carry to earning it.
The dashboard
The dashboard sits in the corner of the chart (position adjustable) and answers two questions without requiring you to read the lines themselves.
The top section shows the active pair in detail: the raw carry spread in percent, its percentile rank over 2 years (504 trading days), the estimated absolute cost or income for your chosen time horizon and position size, and the break-even return. This is the quick answer to "what is this position costing me right now?"
The bottom section is a comparison table listing every currency with valid data. Each row shows the currency name, its carry spread, its current yield, and the projected cost over your horizon. The instrument currency is marked with a triangle. Rows are color-coded: green for pairs that produce income, red for pairs that cost you money. This answers the follow-up question: "would my carry situation improve if I traded a similar instrument denominated in a different currency?"
The dashboard detail showing the active pair section. CHF to USD carry spread is positive, placing it in the 72nd percentile of its 2-year range. The estimated annual cost for a 100,000 position at the 0-100k broker tier is displayed alongside the break-even return.
The comparison table below the active pair section. All currencies are listed with their individual spreads and estimated costs. JPY shows the largest negative spread (income), while USD shows the highest positive spread (cost) from a CHF base perspective.
Setting it up
The Carry Model group contains the five settings that determine everything:
Account Currency : your brokerage base currency. This is the single most important input. Get this wrong and every number on the screen is meaningless.
Yield Maturity : 2Y sits closer to actual funding costs. 10Y captures term premium effects and is useful for longer-horizon strategic planning.
Position Size : the notional value of your position in the instrument currency. Drives the absolute cost estimate.
Cost Horizon : 1 month, 3 months, 6 months, or 1 year. Controls how far out the projection reaches.
Broker Balance Tier : matches the IB tiered structure. Set to "None" to strip out the broker markup entirely and see the pure yield differential.
The Display group controls background shading (green when earning, red when paying) and whether all currency lines appear or only the detected one.
Eight color themes are available (EdgeTools, Gold, Behavioral, Quant, Ocean, Fire, Matrix, Arctic) with dark and light mode support. Line width and glow effects are adjustable.
Three alert conditions can fire:
Carry spread enters the 90th percentile (historically expensive environment)
Carry spread enters the 10th percentile (historically cheap environment)
Carry spread crosses zero (direction flipped)
Practical examples
Example 1 : CHF account trading MES (Micro E-mini S&P 500)
Account currency: CHF. Instrument currency: USD. Assume CH02Y = 0.60%, US02Y = 3.85%.
Carry spread = 3.85 - 0.60 = +3.25% .
Broker markup (0-100k tier) = 1.50%.
Gross carry = 3.25 + 1.50 = 4.75% .
Annual cost on 100,000 USD nominal = 100,000 * 0.0475 * (365/360) = 4,819 USD .
Break-even = 4.75% per year. The S&P 500 must return more than 4.75% annually just to cover carry.
Example 2 : USD account buying CSPX (iShares S&P 500 UCITS, EUR-listed)
Account currency: USD. Instrument currency: EUR. Assume US02Y = 3.85%, DE02Y = 2.05%.
Carry spread = 2.05 - 3.85 = -1.80% .
Broker markup = 1.50%.
Gross carry = -1.80 + 1.50 = -0.30% .
Annual income on 100,000 EUR nominal = 100,000 * 0.003 * (365/360) = 304 EUR .
You earn a small amount because USD yields exceed EUR yields by more than the broker markup.
Example 3 : EUR account trading Nikkei 225 futures (JPY-denominated)
Account currency: EUR. Instrument currency: JPY. Assume DE02Y = 2.05%, JP02Y = 0.15%.
Carry spread = 0.15 - 2.05 = -1.90% .
Broker markup = 1.50%.
Gross carry = -1.90 + 1.50 = -0.40% .
You earn a small net income because borrowing JPY is cheaper than what your EUR balance yields.
These examples show that the carry direction depends entirely on which currency has the higher rate and how large the broker fee is. Pairs close to zero can flip between cost and income whenever a central bank moves.
Limitations
Sovereign yields are not overnight rates. The 2-year bond yield is a proxy, not the exact benchmark brokers use. Interactive Brokers references SOFR for USD, SARON for CHF, ESTR for EUR, SONIA for GBP. The gap between sovereign 2Y yields and these overnight rates typically sits at 20 to 50 basis points (Ilmanen, 2011, p. 364), occasionally more during yield curve inversions.
The broker cost model is simplified. Real IB interest calculations depend on multi-currency balances across the account, unrealized PnL, margin usage, and the interaction between positive and negative currency positions. The indicator applies a single-tier markup, which captures the dominant cost component but may overstate the net cost for larger accounts earning credit interest on their base currency.
Currency detection relies on syminfo.currency . For most futures, ETFs, and equities on major exchanges, this returns the correct settlement currency. Some synthetic instruments, CFDs, or crypto pairs may return unexpected values. Always verify the detected currency in the dashboard header.
Currencies that consistently lacked yield data on TradingView (such as NOK) have been excluded. Missing data for remaining currencies is handled gracefully and does not produce errors.
The indicator works best on the daily timeframe . Intraday charts display yield data that updates once per day, creating flat segments within the session. This does not affect the accuracy of cost estimates.
References
Ilmanen, A. (2011) Expected returns: an investor's guide to harvesting market rewards . Chichester: John Wiley and Sons.
Interactive Brokers (2024) Interest rates on credit and debit balances. (Web Accessed: May 2026).
ISDA (2006) 2006 ISDA definitions . New York: International Swaps and Derivatives Association.
Koijen, R.S.J., Moskowitz, T.J., Pedersen, L.H. and Vrugt, E.B. (2018) 'Carry', Journal of Financial Economics , 127(2), pp. 197-225.
Stigum, M. and Crescenzi, A. (2007) Stigum's money market . 4th edn. New York: McGraw-Hill.
Indikator

Leveraged ETF Volatility Decay Indicator# 杠杆ETF波动率损耗指标 / Leveraged ETF Volatility Decay Indicator
## 它是什么 / What is it
杠杆ETF(如TQQQ、SOXL、UPRO)承诺每日N倍于标的指数的收益率。但由于**每日再平衡**机制,长期持有会产生**波动率损耗(Volatility Decay)**——即使标的指数回到原点,杠杆ETF也会亏损。
本指标直观展示这种损耗的大小,帮助你理解持有杠杆ETF的真实成本。
Leveraged ETFs (e.g. TQQQ, SOXL, UPRO) promise N× the daily return of an underlying index. However, due to **daily rebalancing**, long-term holding incurs **volatility decay** — even if the index returns to breakeven, the leveraged ETF will show a loss.
This indicator visualizes the magnitude of this decay, helping you understand the true cost of holding leveraged ETFs.
---
## 三条线的含义 / What the three lines mean
| 颜色 Color | 名称 Name | 含义 Meaning |
|-----------|-----------|-------------|
| 灰色 Gray | 标的资产 (1x) / Underlying | 标的指数的累计涨跌幅 / Cumulative return of the underlying index |
| 蓝色 Blue | 理论值 (静态杠杆) / Theoretical (static leverage) | N × 标的涨幅,即"借钱买入不调仓"的理想收益 / N × underlying return, the ideal return from static leverage (borrow and hold) |
| 橙色 Orange | 实际杠杆ETF / Actual Leveraged ETF | 模拟每日再平衡后的实际累计收益 / Simulated cumulative return with daily rebalancing |
| 红色填充 Red fill | 损耗区域 / Decay zone | 蓝线与橙线之间的差值 = 被波动率吞掉的收益 / Gap between blue and orange = return eaten by volatility |
**核心公式 / Core formula:**
```
实际杠杆ETF = ∏(1 + N × rₜ) 每日复利
理论静态杠杆 = 1 + N × (标的总涨幅) 简单倍数
损耗 = 理论 - 实际
```
---
## 两种计算模式 / Two calculation modes
### 模式一:固定起始日 / Fixed Start Date
从你指定的日期开始,计算到当前K线的累计损耗。
Calculates cumulative decay from a specified date to the current bar.
**适用场景 / Use case:**
- 分析"如果在某天买入并持有到现在,损耗有多少"
- Analyze "if I bought on date X and held until now, how much decay would I suffer"
### 模式二:滚动窗口 / Rolling Window
每根K线独立计算"最近N个交易日"内的损耗,形成连续曲线。
Each bar independently calculates decay over the last N trading days, forming a continuous curve.
**适用场景 / Use case:**
- 不依赖特定入场日期,适合反复交易的人
- 观察损耗随市场环境(趋势 vs 震荡)的变化
- Not dependent on a specific entry date, suitable for active traders
- Observe how decay changes with market conditions (trending vs choppy)
---
## 参数说明 / Parameters
| 参数 Parameter | 默认值 Default | 说明 Description |
|---------------|---------------|-----------------|
| 杠杆倍数 (N) / Leverage | 2.0 | 模拟的杠杆倍数。2=双倍(如QLD/SSO),3=三倍(如TQQQ/SOXL) / Leverage multiplier |
| 计算模式 / Mode | 固定起始日 | 选择固定起始日或滚动窗口 / Choose fixed start date or rolling window |
| 起始日期 / Start Date | 2024-01-01 | 固定模式下的计算起点,添加指标时可直接在图表上点选 / Start point for fixed mode |
| 滚动天数 / Rolling Days | 60 | 滚动模式下回看的交易日数量 / Lookback period for rolling mode |
---
## 信息表格说明 / Info Table
右上角表格显示以下数据 / The top-right table shows:
| 行 Row | 含义 Meaning |
|--------|-------------|
| 基准价 / Base Price | 起始价 → 当前价 / Start price → current price |
| 标的 (1x) | 标的指数累计涨跌幅 / Underlying cumulative return |
| 理论 (静态Nx) | N倍标的涨幅 = 不调仓的理想收益 / N× underlying return |
| 实际杠杆ETF | 每日再平衡后的真实收益 / Actual return after daily rebalancing |
| 波动率损耗 | 理论 - 实际,单位为百分点(ppts) / Theoretical − actual, in percentage points |
| 年化损耗 | 基于近252日波动率估算,公式 N(N-1)/2 × σ² × 252 / Annualized estimate |
---
## 使用建议 / Usage Tips
1. **推荐加载到标的指数上**(如QQQ、SPY、SOX),而非杠杆ETF本身,因为本指标是用标的的日收益率来模拟杠杆ETF的表现。
**Load on the underlying index** (e.g. QQQ, SPY, SOX), not on the leveraged ETF itself, because this indicator simulates leveraged ETF performance from the underlying's daily returns.
2. **使用日线**。杠杆ETF按日再平衡,日线是最准确的时间尺度。
**Use daily timeframe.** Leveraged ETFs rebalance daily, so the daily chart is the most accurate scale.
3. **观察红色填充区域的厚度变化**:
- 震荡行情 → 红色越来越厚(损耗加速)
- 单边趋势 → 红色很薄甚至变绿(ETF跑赢静态杠杆)
**Watch how the red fill area changes:**
- Choppy market → red grows thicker (decay accelerates)
- Strong trend → red stays thin or turns green (ETF outperforms static leverage)
4. **滚动模式下调整天数**来匹配你的持有周期。持有2个月就设60天,持有半年就设120天。
**In rolling mode, adjust the window** to match your holding period.
---
## 损耗的数学原理 / Math Behind the Decay
标的日收益率为 rₜ,N倍杠杆ETF每日收益为 N×rₜ。
对两者取对数展开到二阶项:
```
ln(1 + N×r) ≈ N×r − N²r²/2
N × ln(1+r) ≈ N×r − N×r²/2
```
差值 = −N(N−1)/2 × r²,累计 T 天后:
```
损耗 ≈ N(N-1)/2 × σ² × T
```
| 杠杆倍数 N | 系数 N(N-1)/2 | 标的日波动率1%时年化损耗 |
|-----------|--------------|----------------------|
| 2x | 1 | ≈ 2.52% |
| 3x | 3 | ≈ 7.56% |
**关键结论 / Key takeaway:** 损耗与波动率的**平方**成正比,与杠杆倍数**非线性**增长。3倍杠杆的损耗是2倍的3倍,而非1.5倍。
Decay grows with the **square** of volatility and **non-linearly** with leverage. 3x leverage has 3× the decay of 2x, not 1.5×.
Indikator
