rogerdehe commited on
Commit
7facfab
·
verified ·
1 Parent(s): 61984c3

add dataset card

Browse files
Files changed (1) hide show
  1. README.md +88 -0
README.md ADDED
@@ -0,0 +1,88 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: mit
3
+ task_categories:
4
+ - time-series-forecasting
5
+ language:
6
+ - en
7
+ tags:
8
+ - crypto
9
+ - cryptocurrency
10
+ - finance
11
+ - ohlcv
12
+ - klines
13
+ - binance
14
+ - futures
15
+ - trading
16
+ pretty_name: Binance USDT OHLCV Klines (spot + futures)
17
+ size_categories:
18
+ - 1B<n<10B
19
+ ---
20
+
21
+ # Binance USDT OHLCV Klines (spot + perpetual futures)
22
+
23
+ Historical OHLCV candlestick (kline) data for **Binance** USDT markets — both
24
+ spot and USDT-margined perpetual futures — stored as zstd-compressed Parquet.
25
+
26
+ ## Coverage
27
+
28
+ | | spot | futures (USDT perp) |
29
+ |---|---|---|
30
+ | **Pairs** | ~490 | ~791 (**includes delisted** — survivorship-bias-free) |
31
+ | **Timeframes** | 1m · 3m · 5m · 15m · 1h · 4h · 1d | 1m · 3m · 5m · 15m · 1h · 4h · 8h · 1d |
32
+ | **History** | 2017-08 → 2025-05 | 2020-05 → **2026-07** |
33
+ | **Extras** | — | sparse `mark` price & `funding_rate` for some pairs |
34
+
35
+ - **Spot** seeded from the DigiTuccar `HistoricalDataForTradeBacktest` snapshot (static, ~2025-05).
36
+ - **Futures** is fresh to 2026-07 and **retains delisted symbols**, so it can be used
37
+ for point-in-time / survivorship-bias-free backtests.
38
+
39
+ ## File layout
40
+
41
+ ```
42
+ {market}/{timeframe}/{PAIR}.parquet
43
+ ```
44
+
45
+ Examples:
46
+ - `spot/1d/BTC_USDT.parquet`
47
+ - `futures/1m/BTC_USDT_USDT.parquet`
48
+ - `futures/1h/BTC_USDT_USDT-mark.parquet` (mark price, where available)
49
+ - `futures/8h/BTC_USDT_USDT-funding_rate.parquet` (funding rate, where available)
50
+
51
+ Spot pairs are `BASE_USDT`; futures pairs are `BASE_USDT_USDT` (USDT-margined perp).
52
+
53
+ Each OHLCV Parquet has columns:
54
+
55
+ | column | type | description |
56
+ |---|---|---|
57
+ | `date` | datetime (UTC) | candle open time |
58
+ | `open` | float | open price |
59
+ | `high` | float | high price |
60
+ | `low` | float | low price |
61
+ | `close` | float | close price |
62
+ | `volume` | float | base-asset volume |
63
+
64
+ ## Usage
65
+
66
+ ```python
67
+ from huggingface_hub import hf_hub_download
68
+ import pandas as pd
69
+
70
+ path = hf_hub_download("rogerdehe/klines-binance",
71
+ "futures/1d/BTC_USDT_USDT.parquet", repo_type="dataset")
72
+ df = pd.read_parquet(path)
73
+ ```
74
+
75
+ Subset / whole dataset:
76
+ ```python
77
+ from huggingface_hub import snapshot_download
78
+ snapshot_download("rogerdehe/klines-binance", repo_type="dataset",
79
+ allow_patterns=["futures/1d/*"]) # e.g. daily futures only
80
+ ```
81
+
82
+ ## Notes
83
+
84
+ - Timestamps are UTC. Timeframe coverage varies slightly per pair (some newer
85
+ listings have shorter history; `1h` futures is a partial subset).
86
+ - `mark` / `funding_rate` files exist only for a subset of futures pairs.
87
+ - The HF **dataset viewer is disabled** (custom per-pair layout); load files directly as above.
88
+ - Data provided **as-is** for research; no warranty of accuracy or completeness.