quantlab.dataset.sharadar.tables#
The Sharadar raw tier: which tables exist, their columns and where they live.
The raw tier is Sharadar’s own rows, kept as parquet under
<download-dir>/sharadar/<code>/, one directory per table. The
acquisition layer writes it and the datasets read it; both take the table
names, the column schemas and the directory layout from this module, so the
writer and the reader cannot disagree. This module only reads; the writers
of the watermarks, bulk-pull records and TICKERS history are in
quantlab.acquisition.sharadar.raw_tier.
Each table has a short code, the lower-cased legacy Sharadar code (sep
for stock prices), which names its directory, and an API name
(stocks), which is what api.sharadar.com/v1.0 calls it. TICKERS’
table column uses the upper-case code in the bulk file (SEP) and the
API name over REST (stocks). Column names and order are Sharadar’s published
schema, verbatim (GET api.sharadar.com/v1.0/schema/<api name>, as of
2026-08-18), with the PostgreSQL types mapped to polars: text to
String, date to Date, double precision to Float64 and
bigint to Int64. A ticker is always String, so NA or 1234
is never read as a null or a number.
Examples#
>>> TABLES["sep"].api_name
'stocks'
>>> raw_table_dir("/data/downloads/sharadar", "sep")
PosixPath('/data/downloads/sharadar/sep')
Classes
One Sharadar table of the raw tier. |
Functions
Return the path of a table's bulk pull, |
|
Add each row's |
|
Return the |
|
Return the Eastern date of a raw file's pull ( |
|
Return when a raw file was pulled, in UTC. |
|
Return a table's raw parquet files: the bulk file, then its windows and updated pulls in pull order. |
|
Return the directory holding one table's raw parquet. |
|
Return the last day every one of |
|
Return the day a table's raw tier is complete through, or |
|
Scan one raw table: its bulk pull overlaid with its later pulls. |
|
Return the TICKERS snapshot of the run that pulled a file at |
|
Return |
|
Return the table with this code. |
|
Return the TICKERS history ( |
|
Return the path of the TICKERS history ( |
|
Return the path of the TICKERS snapshot of a pull, beside |
|
Return the TICKERS snapshots, oldest first. |
|
Return SEP's trading days up to |
|
Return the path a |
|
Return today's date in Sharadar's time zone ( |
|
Return the path a date-window pull of a table is written to. |
|
Return |