quantlab.dataset.massive.short_volume.MassiveShortVolumeDataset#
- class quantlab.dataset.massive.short_volume.MassiveShortVolumeDataset(config)[source]#
Bases:
MassiveRestEventPanelDaily panel of Massive’s short volume totals, by permaticker.
See the module docstring for the variables and the placement.
- Parameters:
- dataset_configMassiveShortVolumeConfig
Sharadar’s raw tier (calendar, universe), Massive’s raw tier and the Ticker map.
Examples
With
configas in the module example:ds = MassiveShortVolumeDataset(config).update() list(ds.panel("2024-03-01", "2024-03-05").data_vars) # ['short_volume', 'short_total_volume', 'short_exempt_volume', 'short_volume_ratio']
- EARLIEST = datetime.date(2024, 2, 6)#
The latest first day of the endpoints read (
MassiveRestPanel.EARLIEST).
- REST_ENDPOINTS = ('short_volume',)#
The REST endpoints read (
MassiveRestPanel).
- STORE_NAME = 'massive_short_volume_1d'#
The store folder under
market/massive(MassiveRestPanel.from_data_root).
- STORE_README = '# massive_short_volume_1d\n\nMassive\'s daily short volume (its REST `/stocks/v1/short-volume`, FINRA\'s daily short sale\nvolume) as a daily panel on Sharadar\'s permaticker axis and SEP\'s trading calendar, the whole\nmarket\'s domestic common stock (SEP\'s default category filter), from 2024-02-06. Variables, each\non the record\'s own trading day, NaN on a day without one: `short_volume` (shares sold short\nacross all venues), `short_total_volume` (total volume across all venues), `short_exempt_volume`\n(short volume exempt from Regulation SHO) and `short_volume_ratio` (percent of the total volume\nsold short). The per-venue columns stay in the raw tier; a record re-read by a later pull\nreplaces the earlier copy, but a day already stored changes only on a rebuild.\n\nEach record is placed on the permaticker the Ticker map gives its ticker on its day; a record it\ncannot place is left out and counted in `massive_short_volume_1d.zarr.unplaced.json`. Built by\n`quantlab.dataset.massive.short_volume.MassiveShortVolumeDataset` from\n`downloads/massive/rest/short_volume`, `market/massive/massive_ticker_map` and Sharadar\'s SEP\nand TICKERS; first built by `scripts/massive/short_volume.py`, then appended day by day by the\ndaily data update. docs/user-guide/massive.md, "Short volume". Licensed data: personal use.\n'#
The store folder’s
README.md.
- VARIABLES = {'short_exempt_volume': {'description': "Short volume marked exempt from Regulation SHO (Massive's exempt_volume).", 'unit': 'shares'}, 'short_total_volume': {'description': "Total volume reported across all venues on the day (Massive's total_volume).", 'unit': 'shares'}, 'short_volume': {'description': "Shares sold short across all venues on the day (Massive's short_volume).", 'unit': 'shares'}, 'short_volume_ratio': {'description': "100 * short_volume / short_total_volume (Massive's short_volume_ratio).", 'unit': 'percent'}}#
The module’s
VARIABLES.
- config_cls#
The config class used to rebuild this dataset from a saved config.
alias of
MassiveShortVolumeConfig