OPEN-SOURCE SCRIPT
Liquidations Aggregated (Lite)

Liquidations Aggregated (Lite)
The Liquidations Aggregated (Lite) script provides a unified cross-exchange visualization of short and long liquidation volumes, allowing traders to identify high-impact market events and sentiment reversals driven by forced position closures. It aggregates normalized liquidation data from Binance, Bybit, and OKX into a single coherent output, offering a consolidated perspective of derivative market stress across major venues.
Core Concept
Liquidations are involuntary closures of leveraged positions when margin requirements are breached. They represent points of structural orderflow imbalance, often triggering localized volatility spikes and price pivots. This indicator isolates and aggregates those liquidation volumes by direction (short vs. long), allowing traders to map where leveraged traders are being forced out and whether current market movement is driven by short covering or long capitulation.
Underlying Methodology
Each connected exchange provides liquidation feeds via standardized symbols (e.g., BTCUSDT.P_LQBUY or BTCUSD.P_LQSELL).
The script differentiates between:
Short Liquidations → Buy Volume: Forced covering of shorts, representing upward pressure.
Long Liquidations → Sell Volume: Forced selling of longs, representing downward pressure.
Bybit’s inverse data is normalized to align directional logic with Binance and OKX. Data is drawn through the request.security() function per symbol and per exchange, with per-exchange scaling adjustments applied to compensate for differences in reported nominal sizes (USD vs. coin-margined). The script is meant to match the calculation methods of professional-grade data sources (e.g., Velodata, Coinalyze). The value is denominated in the base currency at all times.
Computation Logic
Liquidation volumes are fetched separately for USD- and USDT-margined pairs on each exchange.
Exchange-specific magnitude adjustments are applied to account for nominal denomination differences.
Normalized liquidation buy and sell volumes are summed into two global aggregates:
combinedBuyVolumeLiquidationsShort → aggregated buy volume from forced short positions closes (Short Liquidations)
combinedSellVolumeLiquidationsLong → aggregated sell pressure from forced long position closes (Long Liquidations)
Final series are plotted as mirrored column charts around a zero baseline for direct comparison.
How to Use
Apply the script to any crypto perpetual futures symbol (e.g., BTCUSDT, ETHUSDT).
Observe teal bars (Buy Volume from Short Liquidations) for short squeezes and red bars (Sell Volume from Long Liquidations) for long wipes.
Strong teal spikes during downtrends often indicate aggressive short liquidations leading to short-term bounces.
Strong red spikes during uptrends often mark long unwinds that can trigger sharp retracements.
Sustained asymmetry in either direction suggests systemic imbalance across leveraged positioning.
The Liquidations Aggregated (Lite) script provides a unified cross-exchange visualization of short and long liquidation volumes, allowing traders to identify high-impact market events and sentiment reversals driven by forced position closures. It aggregates normalized liquidation data from Binance, Bybit, and OKX into a single coherent output, offering a consolidated perspective of derivative market stress across major venues.
Core Concept
Liquidations are involuntary closures of leveraged positions when margin requirements are breached. They represent points of structural orderflow imbalance, often triggering localized volatility spikes and price pivots. This indicator isolates and aggregates those liquidation volumes by direction (short vs. long), allowing traders to map where leveraged traders are being forced out and whether current market movement is driven by short covering or long capitulation.
Underlying Methodology
Each connected exchange provides liquidation feeds via standardized symbols (e.g., BTCUSDT.P_LQBUY or BTCUSD.P_LQSELL).
The script differentiates between:
Short Liquidations → Buy Volume: Forced covering of shorts, representing upward pressure.
Long Liquidations → Sell Volume: Forced selling of longs, representing downward pressure.
Bybit’s inverse data is normalized to align directional logic with Binance and OKX. Data is drawn through the request.security() function per symbol and per exchange, with per-exchange scaling adjustments applied to compensate for differences in reported nominal sizes (USD vs. coin-margined). The script is meant to match the calculation methods of professional-grade data sources (e.g., Velodata, Coinalyze). The value is denominated in the base currency at all times.
Computation Logic
Liquidation volumes are fetched separately for USD- and USDT-margined pairs on each exchange.
Exchange-specific magnitude adjustments are applied to account for nominal denomination differences.
Normalized liquidation buy and sell volumes are summed into two global aggregates:
combinedBuyVolumeLiquidationsShort → aggregated buy volume from forced short positions closes (Short Liquidations)
combinedSellVolumeLiquidationsLong → aggregated sell pressure from forced long position closes (Long Liquidations)
Final series are plotted as mirrored column charts around a zero baseline for direct comparison.
How to Use
Apply the script to any crypto perpetual futures symbol (e.g., BTCUSDT, ETHUSDT).
Observe teal bars (Buy Volume from Short Liquidations) for short squeezes and red bars (Sell Volume from Long Liquidations) for long wipes.
Strong teal spikes during downtrends often indicate aggressive short liquidations leading to short-term bounces.
Strong red spikes during uptrends often mark long unwinds that can trigger sharp retracements.
Sustained asymmetry in either direction suggests systemic imbalance across leveraged positioning.
開源腳本
本著TradingView的真正精神,此腳本的創建者將其開源,以便交易者可以查看和驗證其功能。向作者致敬!雖然您可以免費使用它,但請記住,重新發佈程式碼必須遵守我們的網站規則。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。
開源腳本
本著TradingView的真正精神,此腳本的創建者將其開源,以便交易者可以查看和驗證其功能。向作者致敬!雖然您可以免費使用它,但請記住,重新發佈程式碼必須遵守我們的網站規則。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。