In this mini-series, we will export continuous futures data from Sierra Chart as a CSV and import it to Zorro in T6 format. I will assume the reader has some basic knowledge of how futures work. For this post, I will focus on the data acquisition.
Continuous Contracts in Brief
First of all, a “continuous futures contract” is not a real tradeable asset, but rather a means to represent every sequential contract for a given futures ticker symbol. The “continuous contract” is a series of synthetic open-high-low-close bars for a single futures ticker symbol, so that you can ignore the transition from one contract to the other. A continuous contract can be either daily bars or intraday bars. Strictly speaking, a continuous contract is an indicator.
There are different ways to rollover from contract-to-contract, such as jumping straight from contract to contract or some type of smooth transition. I will not go into details about rollovers, but you should note that the rollovers should be carefully selected for a given contract in order to avoid bad signals.
For example, the E-Mini contract typically has the ticker symbol “ES”. You cannot trade “ES” per se. Rather, you must trade a specific contract with a specific expiration date. For example, you can trade the September 2019 ES contract, typically symbolized as “ESM19”. (Note that exact futures symbols vary from broker to broker, even while representing the same asset from the same exchange.)
Using a program such as Sierra Chart, you can generate a Continuous Contract representation of the ES symbol.
Using Sierra Chart for Historical Data
Sierra Chart is my go-to for most historical data (except options). Here’s why:
- Relatively inexpensive for historical data only. (The price gets steep if you add live data feeds, but this is mostly exchange fees.)
- Access to years of intraday and daily historical data for a relatively low price.
- It can construct continuous contracts for you. Multiple rollover configurations are available.
- Historical data is available for most exchanges.
Downloading Contract Data
Enough talk, let’s construct a continuous ES contract!
It will be one-minute bars, and it will span ten years.
- Open Sierra Chart
- Make sure you are connected to the Sierra Chart Historical Data Service.
- File >> Find Symbol
- Browse to “Futures – Indices” >> “ES?## | E-Mini S&P 500 Index (ES) – GBLX” >> “ESM19 | June 2019” (or any live ES contract for that matter)
- Click “Open Intraday Chart”
- You now have an ESM19 chart open.
- Right-click the chart >> Chart Settings
- “Advanced Settings” tab.
- Set “Continuous Contract” from “None” to “Continuous Futures Contract – Date Rule Rollover”
- Click “Apply”. The chart will morph into a continuous contract representation.
- Still under Chart Settings, go to “Main Settings” tab.
- On the left, select “Use Number of Days To Load”. We will set it to “3650” for ten years.
- Click “OK”.
- Wait. It could take several minutes. Sierra Chart will first download all of the data, and then it will spend time constructing the continuous contract.
- The chart is now visible again.
- Right-click on the chart >> “Studies”
- In the left column, click on “Write Bar Data To File”, and click “Add>>”.
- Now click on the newly added study in the right column, and then click “Settings”.
- Set the field “Use GMT Time” to “Yes”.
- Click “OK” for the write study.
- Click “OK” again for Chart Studies.
- Wait for the window to disappear. This could take a couple of minutes. Sierra Chart is writing a file for you.
- The dialog window has disappeared.
- Browse to your Sierra Chart folder. Open the file under Data\ESM19-BarData.txt (with Notepad++).
Congratulations, you now have the CSV file! (It has a TXT extension.)
Here’s what it looks like:
In the next part of our series, we will parse the CSV data into the T6 format. Look forward to it!