How Convexity Labs computes its numbers
Every figure in the terminal comes from public market data and a formula you can check. This page lists the data, how often it updates, how each metric is calculated, and — as importantly — what each one assumes and where it can be wrong.
Data sources
| Input | Source | Update |
|---|---|---|
| BTC spot (index) | Deribit btc_usd price index, streamed over WebSocket | Every tick |
| Options chain: open interest, mark implied volatility, expiry | Deribit get_book_summary_by_currency for BTC options | Every 30 s |
| Realized volatility | Binance BTCUSDT daily candles, 30-day standard deviation of log returns, annualised (×√365) | Every 30 s |
| Option trade prints | Deribit public trades.option.BTC channel — every trade, with the taker's side | Real time (≈14,000 prints a day) |
| Order book and trades | Binance BTCUSDT level-2 book and aggregate-trade stream | Real time |
By default every listed BTC expiry from 0 to 365 days is included; the terminal can narrow the window. Each contract is 1 BTC. Contracts with no implied volatility are dropped; contracts with zero open interest remain but contribute nothing.
Gamma exposure
For each contract, gamma is Black-Scholes gamma using Deribit's mark implied volatility and a 5% rate:
Global GEX is the sum of net_gex over every strike. Local GEX
weights each strike by its distance from spot, exp(−|K − S| / λ) with λ = 2% of spot,
so the strikes price can actually reach dominate.
The positioning assumption
Open interest does not say who is long. Convexity follows the standard convention: dealers are treated as long calls and short puts, so calls add positive gamma and puts negative. This is an assumption, not a measurement. Where customers have actually bought calls or sold puts in size, the sign at those strikes is wrong.
Separately, Convexity records the taker side of every BTC option trade Deribit prints. A taker buy suggests a dealer sold (dealer short); a taker sell suggests a dealer bought. That is a strong proxy for dealer side, not ground truth — some takers are themselves professionals. These records are archived today and are not yet used in the GEX numbers above; using them to replace the convention with measured positioning is the next step on the roadmap.
Gamma flip
The book is re-priced at 100 hypothetical spot prices across ±30% of spot. The zero crossing of net GEX nearest to spot is then refined with Brent's method to within $1. If net GEX never changes sign in that range, no flip is reported.
Gamma walls
Walls are the five strikes above spot and the five below with the largest absolute net GEX. Each gets a strength score that favours size and closeness:
Regime, pin and breakout scores
The regime label — Total pin, Long gamma, Squeeze, Short gamma, Neutral — comes from local GEX
against thresholds scaled to the size of global GEX, plus the gamma slope (a central difference at ±0.5% of
spot). Regime strength is min(|local| / squeeze threshold, 1) × 100.
The pin, suppression and breakout figures are heuristic scores between 0 and 1, built from local GEX, gamma slope, distance to the flip and the implied-to-realized volatility ratio. They rank conditions; they are not calibrated probabilities and have not been validated against outcomes. Calibrating them against the archive is planned.
Order flow
Cumulative volume delta (CVD) and footprint candles are built from Binance BTCUSDT aggregate trades, attributed to buyer or seller by the aggressor flag the exchange provides. The depth ladder and book heatmap come from the level-2 order book. These are spot-market measures; they are not combined into the GEX figures.
History and backtesting
A GEX snapshot, including the full strike profile and the walls, is archived every 30 seconds, alongside every trade and every change in open interest, to a time-series database. Backtests replay that archive with structural lookahead prevention: a strategy can only read data stamped before the moment it decides on, enforced by the replay engine.
Known limitations
- The dealer positioning convention above is the largest source of error.
- Gamma uses Black-Scholes on spot with a flat 5% rate, not a fitted forward and rate curve.
- Only Deribit options are included; BTC options on other venues and on ETF underlyings are not.
- Open interest updates when Deribit publishes it, so intraday positioning changes lag.
- Pin and breakout scores are uncalibrated heuristics, as noted above.