# Historical Data

This directory may contain the historical data for any number of currency pairs.

## Format

The data for each currency pair must be stored in a JSON file named `<base>-<quote>.json`.

Each JSON file must contain an array of historical samples, ordered by time.

Each historical sample must contain the following fields:

| Field    | Type   | Semantics      | Description                                     |
| -------- | ------ | -------------- | ----------------------------------------------- |
| `time`   | Number | UNIX timestamp | The opening time of the trading period.         |
| `open`   | Number | Currency       | The price at the opening of the trading period. |
| `close`  | Number | Currency       | The price at the closing of the trading period. |

Compatible files can be generated by the `@davidosborn/crypto-history-parser` npm package.
