File size: 1,502 Bytes
e369717
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
## Intro
The data organization follows TFB format: https://github.com/decisionintelligence/TFB.

## TFB data format

TFB stores time series in a format of three column long tables,  which we will introduce below:

### Format Introduction

**First column: date** (the exact column name is required, the same applies below.)

- The columns stores the time information in the time series, which can be in either of the following formats:
  - Timestamps in string, datetime, or other types that are compatible with pd.to_datetime;
  - Integers starting from 1, e.g. 1, 2, 3, 4, 5, ...
  

**Second column: data**

- This column stores the series values corresponding to the timestamps.

**Third column: cols**

- This column stores the column name (variable name).

  


### Multivariate time series example:

**A common time series in wide table format:**

| date | channel1 | channel2 | channel3 |
| ---- | -------- | -------- | -------- |
| 1    | 0.1      | 1        | 10       |
| 2    | 0.2      | 2        | 20       |
| 3    | 0.3      | 3        | 30       |

**Convert to TFB format:**

| date | data | cols     |
| ---- | ---- | -------- |
| 1    | 0.1  | channel1 |
| 2    | 0.2  | channel1 |
| 3    | 0.3  | channel1 |
| 1    | 1    | channel2 |
| 2    | 2    | channel2 |
| 3    | 3    | channel2 |
| 1    | 10   | channel3 |
| 2    | 20   | channel3 |
| 3    | 30   | channel3 |

## License  
This dataset is released under [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/deed.en)