The implied market cap S
S is what an IPO event's options say the company is worth if it lists. The chain computes it
every block from the options' own order books and publishes it as the oracle price of
{BASE}CAP-USD (for a company expiry, {BASE}Y{YYMM}CAP-USD). Call margin and the call marks
read it, and the company index blends the expiries' S.
Conditional put-call parity
A call minus a put at the same strike pays cap − K if the IPO happens and nothing if it doesn't, so C − P = p·(F − K), with F the expected cap given an IPO and p the probability of an IPO. Each strike gives an estimate:
F = K + (C − P) / p
How it is computed
- Samples. Every block the chain looks at each book of each trading event: the best bid
and ask, the mid, and the depth within 5¢ of the mid (
depth_band_ticks, counted in cents on every book, the binary's too, whose own tick is 0.1¢). It reads only long-term orders placed before the block, which are in chain state. Short-term orders live only in each validator's memory, so they don't count. A book with one side empty, or crossed, gives no sample. Only quotes that could really trade count:- covered together: a subaccount's quotes on a side count only if it could pay for all of them at once, re-checked every block; a subaccount holding a position in another market doesn't count;
- one book a subaccount: a long-term order is refused unless its subaccount can cover it with its other resting long-term orders on that side, and while the subaccount has long-term orders resting on another chain-market book;
- price levels: the first 16 levels a side (
max_scan_per_side, 1 to 32), at most 64 orders a side. A level is a cent wide, so on the binary's book up to ten of its prices make one level; - 4 orders a subaccount: at most a subaccount's 4 best orders on a side count. Its further orders there are read for its cover but count for nothing, so one subaccount can't fill the 64 and hide the other quotes;
- no one dominates: each subaccount's depth on a side counts at most 50 contracts (10 × the minimum depth);
- a market, not a quote: a sample counts only with at least 5 contracts
(
min_depth) from at least 2 subaccounts (min_quoters) on each side.
- Averages. Each book keeps its last 60 blocks of samples (
window_blocks); its price is the average mid of its valid samples, counted with at least 40 (min_valid_samples). - Hold below 25%. While p is under 25% (
p_floor_ppm), or the binary has no average, S is held: dividing by a small p would magnify noise. - Strikes. A strike counts when both its call and its put have valid averages. Of those,
the 4 nearest the current S are used (
max_strikes), each weighted by its depth. - Collar. S moves toward the weighted estimate by at most 0.5% a block
(
collar_ppm). - Hold. When no strike qualifies, the last value is kept and S is flagged stale, with the reason. The first value is the reference market cap set at listing. When the event resolves Yes, S becomes the final market cap.
- Margin while stale. While S is stale, the price call margin and the call floors read (the oracle price of the CAP market) never falls, and climbs toward S's recent high (the highest S of about the last 60 blocks before it went stale) by at most 0.5% a block. The published S stays the held value.
The record also carries depth_used: over the strikes used, the sum of the lesser of the
call's and the put's depth. The company index weighs an expiry by it.
The binary price p
p is the binary book's average (the same 2-subaccount, 5-contract minimums), but it moves
at most 2¢ a block (binary_price_step_ppm) from the p the chain last used, and stays
within 10¢ of a slow reference (binary_price_reference_band_ppm) that follows p by 1/600 of
the gap each block (binary_price_reference_blocks). While the binary has no average, p drifts
back toward the 25% floor the same way. p and its reference start at the binary's listing
price.
So once p is 10¢ from its reference it moves only as fast as the reference: about 1¢ in 60 blocks. Moving p by N¢ (N > 10) takes about 5 + 60·(N − 10) blocks: 20¢ about 10 minutes and 60¢ about 50 minutes, at about a second a block. An unquoted call's model uses the lesser of p and its reference.
Reading it
curl -s https://api.testnet.firstaccess.exchange/dydxprotocol/binary/implied_price/1implied_price has value (S, micro-$B), reference_cap, stale, stale_since_height,
hold_reason, strikes_used, binary_price (p, ppm), binary_price_reference,
depth_used and the event's params. Each parameter's default and bounds are in the
parameter reference. Long stale runs emit
implied_price_held every block.
Quoting so S moves
Quote every book with long-term orders, one subaccount per book and at least two subaccounts a side, at least 5 contracts within 5 ticks of the mid. At a market cap S and an IPO probability p, quote the binary at p, the call at K at p·max(0, S − K) + c and the put at p·max(0, K − S) + c, for any common c: then C − P = p·(S − K) and every strike says S.