|
|
Prior to using exporting historical data from Excel, you must first, create a synthetic symbol in the Aspen database.
Make sure that an entry for your created symbol has been made in the Symbol Info List so that it will accept the data you want to export.
The field order in Excel is important. You must have the data in the order prescribed by the database file you intend to update. The following table is an example of daily data in Excel that can be written to days.dat file in Aspen:
corn_spread |
hloc |
|
|
|
|
5/1/97 |
6:00 |
16 |
13.75 |
14 |
16 |
5/2/97 |
6:00 |
15.75 |
14.5 |
14.5 |
15.25 |
5/5/97 |
6:00 |
16.5 |
15 |
15 |
16.5 |
5/6/97 |
6:00 |
16.5 |
16 |
16.5 |
16 |
5/7/97 |
6:00 |
16.5 |
15 |
16.5 |
15 |
5/8/97 |
6:00 |
15 |
14.5 |
15 |
14.75 |
The arrangement of data in this manner comprises an export array. An export array consists of two parts: a header and a body. The header is the first line of the array. The body is the rest of the array.
The header contains two fields: the first field defines the targeted synthetic symbol, here, "corn_spread"; the second field contains a string defining the price arrangement of fields that follow. In the example above, the second field defines "hloc", or "high low open close".
There are five order options you can use in the header's second field.
Option |
Data |
Database |
Field Order |
tickhist |
Tick data |
Ticks.dat |
Date, Time, Price, Volume |
hloc,15 |
15 minute data |
Bars.dat |
Date, Time, High, Low, Open, Close |
hlocv,15 |
15 minute data |
Bars.dat |
Date, Time, High, Low, Open, Close,Volume, Open Interest |
hloc |
Daily data |
Days.dat |
Date, Time, High, Low, Open, Close |
hlocv |
Daily data |
Days.dat |
Date, Time, High, Low, Open, Close, Volume, Op Int |
To export the data into Aspen, highlight the entire array (Header and Body). Then click the export (pointing hand) icon in the Aspen button bar.