Docs · 01
Measurement methodology
Mid definition, slippage, size buckets, market states, exclusions.
This page defines how a single trade is measured and how trades are grouped into scores. Every parameter listed as governed can be changed by $PRGE governance; changes apply from the next reporting day and are versioned in the report.
Mid
The mid for a trade is the Chainlink price for the Stock Token that is current at the block in which the trade is included. "Current" means the latest round with an update timestamp at or before the block timestamp.
- If the latest round is older than the feed's heartbeat plus a grace period, the mid is unavailable and the trade is excluded.
- No venue price, TWAP or aggregator quote is ever used as the mid. The reference is external to every venue measured.
- The feed address per Stock Token is part of the governed configuration and is recorded in each report.
Slippage
For each swap, the fill price is the quote amount divided by the Stock Token amount actually transferred, including any venue fee. Gas is excluded.
buy: slippageBps = (fillPrice − mid) / mid × 10 000
sell: slippageBps = (mid − fillPrice) / mid × 10 000Positive slippage is a cost to the trader. Negative slippage is price improvement and is kept as a negative value in the dataset.
Size buckets
Trade size is measured as the USDG notional at the mid. Initial buckets (governed):
| Bucket | Notional (USDG) |
|---|---|
| 0 | < 1,000 |
| 1 | 1,000 – 9,999 |
| 2 | 10,000 – 49,999 |
| 3 | 50,000 – 249,999 |
| 4 | ≥ 250,000 |
Market states
Each trade is tagged with the state of the underlying equity's primary market at the block timestamp.
| State | Definition |
|---|---|
| Open | Regular trading session of the primary listing. |
| PrePost | Pre-market and after-hours sessions. |
| Closed | Overnight, weekends and exchange holidays. The mid is the last available mark. |
| Halt | A trading halt on the primary listing is in effect. |
The state is taken from the oracle's market-status field where the feed provides one, and otherwise from the published exchange calendar and halt notices. The source used is recorded per report.
How halts are excluded
- Trades in blocks between the start of a halt and the first oracle update after resumption are tagged Halt.
- Halt trades are never scored. They are listed in the dataset for transparency but contribute to no leaf.
bestVenuecalled withMarketState.Haltalways returnsaddress(0),scoreBps = 0.
Aggregation
A score is computed for each venue × token × size bucket × market state over one UTC day.
- scoreBps — the notional-weighted median of trade slippage, rounded to the nearest bps and floored at 1. The floor keeps 0 reserved as the "no fresh score" sentinel (see Reading scores).
- sampleSize — the number of trades in the cell.
- Cells with fewer trades than the minimum sample size (governed) are published but are not eligible for
bestVenue. - Trades by addresses flagged as wash trading under the published heuristics are excluded; the flag list is part of the dataset.
Reproducibility
The indexer is open source. Each report pins the indexer version, feed addresses, venue list and parameters, so any third party can recompute every leaf from public chain data.