OPEN-SOURCE SCRIPT

BTC Flow Dashboard : Spot Premium + OI + Funding + Cycle Signals

200
Spot Premium vs Perpetual Basket (%):
Tracks how aggressively perps are trading relative to spot, a leading indicator of speculative activity and leverage buildup.

Aggregated Open Interest Z-Score:
A normalized view of OI expansion/contraction across major exchanges (Binance, BitMEX, Bybit, Kraken, etc.), highlighting when leverage enters overheated zones.

Composite Funding Rate Analysis:
Calculates a TWAP-smoothed funding composite across major venues, with optional APR scaling, showing where perpetual markets are paying for long or short exposure.

Confluence Signal Engine:
Dynamically flags bullish or bearish market conditions based on premium behavior and leverage environment — including over-leverage warnings that often precede volatility spikes.

Extreme Cycle Tops & Bottoms (Experimental):
Optional signal module that highlights historically significant extremes (e.g., 2020 bottom or 2021 top) based on statistical Z-score thresholds across the three core metrics.

Notes & Tips
Works best on weekly or monthly timeframes for macro cycle analysis.

Daily and 3D views provide short-term leverage context but may produce more frequent signals.

The Extreme Signal Engine is experimental — not a trading signal on its own, but a contextual tool to support macro decision-making.

Disclaimer

The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.