Dataset Fundamentals

What Is a Polymarket Dataset? A Practical Guide

Learn what a Polymarket dataset contains, how market, order book, delta, trade, and resolution records connect, and how researchers use them.

polytestdata.xyz5 minute read
Polymarketdatasetsorder bookstrades

Quick answer

A Polymarket dataset is a structured collection of historical information from Polymarket prediction markets. It can contain market questions, outcome tokens, opening and closing times, prices, order books, completed trades, and final resolved outcomes.

Researchers use this data to understand how prediction market prices changed, how much liquidity was available, what trades occurred, and whether a historical strategy would have worked under defined assumptions.

A complete dataset is more useful than a simple price list because it preserves the relationship between the market, its outcome tokens, its order book activity, its trades, and its final result.

What is Polymarket?

Polymarket is a prediction market platform. Markets ask questions about future events and provide outcome tokens representing possible answers.

A crypto market might ask whether Bitcoin will move up or down during a five-minute period. Traders buy and sell outcome tokens, and their prices change as expectations change.

When the event ends, the market is resolved. The winning outcome settles as true, while the other outcome settles as false.

What information can a Polymarket dataset contain?

A research-ready dataset can include several connected types of records.

| Data type | What it represents | Common use | | Market metadata | The question, identifiers, times, tokens, and outcome | Filtering and labels | | Order book snapshots | Complete bids and asks at one point in time | Liquidity analysis | | Order book deltas | Individual changes between full snapshots | Market replay | | Trades | Completed transactions | Trade flow analysis | | Resolution data | The final winning outcome | Backtest evaluation |

Each record type answers a different question. Market metadata explains what was traded. Snapshots show available liquidity. Deltas show how the book changed. Trades show completed activity. Resolution data provides the final result.

Market metadata

Market metadata is the foundation of the dataset. It identifies the market and describes its lifecycle.

Common fields include:

  • market_id for the Polymarket condition identifier
  • question for the complete market question
  • open_time_ms for the opening time
  • close_time_ms for the closing time
  • resolved_at_ms for the resolution time
  • outcome_names for possible outcomes
  • token_ids for outcome token identifiers
  • winning_outcome for the final result
  • tick_size for the minimum price increment

The market_id usually acts as the main join key. It connects the market table with snapshots, deltas, and trades.

Full order book snapshots

An order book snapshot is a complete view of available bids and asks at a specific time.

A bid represents an available buy order. An ask represents an available sell order. Each level usually contains a price and size.

Useful snapshot values include:

  • Best bid
  • Best ask
  • Bid-ask spread
  • Midpoint
  • Total bid depth
  • Total ask depth
  • Number of bid levels
  • Number of ask levels

Snapshots can help a researcher understand whether a displayed market price was supported by meaningful liquidity.

Order book deltas

Saving a complete order book after every change can produce very large files. A more efficient method is to save periodic full snapshots and record individual changes between them.

These individual changes are called deltas.

A delta generally contains:

  • The related market
  • The parent snapshot
  • The changed price
  • The new size
  • The book side
  • The exchange timestamp
  • The collection timestamp

A new size of zero normally means that the price level was removed.

Deltas make it possible to reconstruct the order book over time when they are applied in the correct order after a valid full snapshot.

Trade records

Trade records describe completed transactions.

Common trade fields include:

  • Trade identifier
  • Market identifier
  • Platform timestamp
  • Collection timestamp
  • Execution price
  • Executed size
  • Trade side
  • Reported fee rate

Trades and order book changes should not be treated as identical information. A trade reports completed activity, while a delta reports a visible order book level change.

Resolved outcomes

Resolved outcomes are important for supervised learning and backtesting.

A resolved market tells the researcher which outcome eventually became true. That result can be used as a label or as the final settlement value in a simulation.

The resolved outcome is future information before the market ends. A valid historical test must not expose that result to a strategy before the simulated resolution time.

Using final outcomes too early creates look-ahead bias and makes a strategy appear better than it could have been in live conditions.

Why use Parquet?

Parquet is a column-oriented data format designed for analytical workloads.

It is useful for market datasets because it supports:

  • Efficient compression
  • Typed columns
  • Fast selection of relevant fields
  • Nested bid and ask structures
  • Compatibility with Python and data tools
  • Large datasets that would be awkward in CSV

Zstandard compression can reduce storage size while preserving efficient analytical access.

How the files connect

A common dataset structure uses four files:

  1. Start with markets.parquet.
  2. Select a market_id.
  3. Load snapshots with the same market_id.
  4. Apply deltas in timestamp order.
  5. Load trades for the selected market.
  6. Compare a simulated strategy with the resolved outcome.

The market table acts as the spine of the dataset. Snapshot chains can use a separate snapshot_id to identify the correct reconstruction starting point.

What can researchers study?

Polymarket datasets support many forms of analysis.

Researchers can study:

  • Price behavior before market close
  • Changes in bid-ask spreads
  • Liquidity near resolution
  • Order book imbalance
  • Trade frequency
  • Trade size distribution
  • Relationship between prices and outcomes
  • Differences across crypto assets
  • Short-horizon prediction market behavior
  • Possible trading strategy rules

The correct dataset depends on the question. A simple price history may support trend analysis, while execution research requires full order book depth and realistic fill assumptions.

Training and testing datasets

Historical Polymarket records can be converted into machine learning samples.

Features may include spread, midpoint, depth, imbalance, recent trade volume, volatility, time remaining, and recent price movement.

Labels may include the final outcome or a future price movement over a fixed horizon.

Training, validation, and testing periods should be separated by time. Randomly mixing rows from the same markets can leak future information and create unreliable evaluation results.

Important limitations

A historical dataset does not reproduce every live condition.

Real trading may include:

  • Network latency
  • API delays
  • Rejected orders
  • Partial fills
  • Queue position
  • Changing fees
  • Missing messages
  • Unavailable liquidity
  • Rapid market changes

Historical research should include conservative assumptions and clear documentation.

Final summary

A Polymarket dataset connects market identity, prices, liquidity, trades, timestamps, and final outcomes. The strongest datasets preserve enough detail to support repeatable research and realistic backtests.

The Polymarket BTC five-minute TWAP dataset includes market metadata, complete order book snapshots, deltas, trades, and resolved outcomes in compressed Parquet files.

Last updated . This article is for research and educational purposes. Historical market results do not guarantee future performance.

Back to all guides