Premium Data Converter Help
Current Version: 1.0.7.1
Released: 3rd July 2020
This application is designed to convert "MetaStock" (MS) format data to text (ascii). It offers a wide range of configurable parameters so that you can get the exact type of ascii data you need.
As you change the parameters, you can see what the converted data will look like by use of the "Show Format Example" command.
The application remembers the changes you make and will offer the last recorded configuration whenever it is re-opened.
To jump to information about any of the configurable format parameters, click on one of the links below:
Output Fields
Number of Decimal Places
Date Format
Field Delimiter
Decimal Separator
File Extension
Wrap Fields in Quotes
Insert Header Row
Dummy Time Value
Date Sort Order
Periodicity
Or you can jump straight to the FAQ
Data Folders
Source Folder (MS)
To set the appropriate Source Folder, either -
- Type the name of the folder that holds the MS format data you wish to convert
- Or copy and paste the folder name using Windows
- Or click on the folder icon to navigate to the desired folder and then select it
Source data is typically organised in a hierarchical tree structure, as shown in the illustration below.
If you wish to convert the contents of a specific sub-folder, select that sub-folder as the Source Folder.
Otherwise, choose the "top level" folder of your MS database to convert all sub-folders at lower levels.
For instance, to convert Premium Data's entire US Stocks database, select "c\Trading Data\Stocks\US".
To convert just the NYSE folder, select "c\Trading Data\Stocks\US\NYSE".
Click here for an illustration of the hierarchical tree structure
Hide illustration
Exclude Folders
If you have chosen a higher level folder as your Source Folder, you can exclude specific lower level sub-folders from conversion by entering the relevant folder names here.
For instance, if you wish to convert your entire US Stocks database with the exception of the "OTC" folder, then -
- Enter "c:\Trading Data\Stocks\US" as the Source Folder
- Enter "c:\Trading Data\Stocks\US\OTC" as an item under Exclude Folders
You can nominate more than one folder to exclude by listing the folder names on separate lines, as shown in the illustration further below.
Hint: when entering a folder to be excluded, you can speed up the process by typing just the relative path (the path relative to the Source Folder).
For instance, instead of typing in "c:\Trading Data\Stocks\US\OTC", just type in "OTC".
Click here for an illustration
Hide illustration
Destination Folder (Text)
Enter the name of the Destination Folder here. In addition to the converted ascii files, the Destination Folder will hold a file called "names.txt",
which will contain a list of all the symbols that were converted, along with their market names and the name of the sub-folder where the converted file can be found.
Note: the Destination Folder will not contain alphabetical sub-folders.
For instance, the MS format data in your "c:\Trading Data\Stocks\US\NYSE" folder may be organised into A-Z sub-folders.
However, this alphabetical sub-structure will not be carried across to the Destination Folder.
Note 2: if the Destination Folder already contains output from a previous
conversion, the output is not cleared before a subsequent conversion. Please refer to our
FAQ on this topic for an explanation.
Configurable Parameters
Output Fields
This section allows you to define which fields are included in the ascii output.
To select or de-select a field, highlight the field name first and then click in the corresponding tick box.
To change the field order, highlight a field name and then click the appropriate "move item" button to move it up or down the order.
Note: the "Date" field is always required and cannot be de-selected.
Number of Decimal Places
This section allows you to selectively define the number of decimal places in the output.
"Volume" and "Open Interest" are invariably integer values and don't require a decimal expansion.
However, Premium Data's US Stocks data contains the "Unadjusted Close" in the otherwise redundant Open Interest field.
If you are converting US Stocks and require the Unadjusted Close in the output, treat Open Interest as a price field and set the number of decimal places accordingly.
Date Format
To set the Date Format, use the letters d, m and y to represent the number of digits for Day, Month and Year. For instance, to set a date format of 20100930, type in yyyymmdd.
At any time you can verify that you have entered a valid date format by clicking the "Show Format Example" button.
More Information on Date Formatting
Hide
Date delimiters can be virtually any special character however the standard date delimiters are -
/ Forward slash
- Dash
. Period
Some examples of valid date formats include: mm/dd/yy, d-mm-yy and mm.dd.yyyy.
Date Format Combinations
Using "Sunday the 8th of March 2009" as an example, the following combinations are possible:
d | 8 | m | 3 | y | 9 |
dd | 08 | mm | 03 | yy | 09 |
ddd | Sun | mmm | Mar | yyy | 009 |
dddd | Sunday | mmmm | March | yyyy | 2009 |
Field Delimiter
Standard field delimiters for ascii data are offered from the drop-down menu (the Field Delimiter determines the way in which the data fields are separated).
If you choose "Fixed Width" as the delimiter, the Field Width edit box allows you to define the width by number of characters.
Decimal Separator
This setting determines how a decimal expansion is separated from the integral part of a fractional number. The two choices are -
Period (Full Stop) | 96.125 |
Comma | 96,125 |
Note: a choice of "Comma" for Decimal Separator may be incompatible with a similar choice for Field Delimiter.
This is because a program trying to read the data may interpret each separator comma as a field break. When "Comma" is selected as the Decimal Separator,
Premium Data Converter automatically assumes that Wrap Fields in "Quotes" should be ticked.
If you definitely want the application to allow "Comma" as the decimal separator without the fields being wrapped in quotes, make sure to untick that latter selection.
File Extension
Standard file extensions for ascii files are "txt", "csv" (comma separated values) and "prn". However, the application allows any extension to be defined.
Wrap Fields in Quotes
Tick this setting to surround each field in the output with quotation marks.
Insert Header Row
Tick this setting to include a header row at the top of each ascii file which identifies the field names in the output.
Dummy Time Value
The Premium Data end of day files do not contain a time value. If your charting package requires a time field in the ascii files, select the "Dummy Time" output field and enter a dummy time value here.
This dummy time is inserted directly into the output files so you can use whatever time value and formatting you require eg: 16:30:00, 4pm, 15:00 etc.
Date Sort Order
The output files can be sorted by date ascending (with the oldest date first at the top of the file) or descending (with the newest date first at the top of the file).
Periodicity
This controls the range of price records that are contained in the output files. The options are Daily, Weekly and Monthly.
Start Date
Leave this setting at the default value (1st January 1880) unless you specifically wish to constrain the date range of the output.
End Date
Leave this setting at the default value (which should be the current date according to your computer's clock) unless you specifically wish to constrain the date range of the output.
Show Format Example
Click the "Show Format Example" button to see an example of how the output will appear according to the currently selected options for the various format parameters.
The example will be shown in the window at the bottom of the application.
FAQ
Can I get the Premium Data Converter to run automatically?
Yes. You can create a task in the Windows Task Scheduler to convert the MS data automatically at a preferred time. Click on "more information" below for full instructions.
More Information
Hide
Windows 8 and 10
1. Go Start and type "Task Scheduler"
2. Task Scheduler - under "Actions" on the right, click Create Basic Task.
3. Create Basic Task - enter a suitable name (and description). [Next]
4. Task Trigger - select Weekly. [Next]
5. Weekly - set the Start date and time.
6. Weekly - select days Monday to Saturday (typically). [Next]
7. Action - select Start a Program. [Next]
8. Start a Program - click Browse. Then navigate to the "c:\Program Files\Premium Data Converter" folder and open it.
Find "Premium Data Converter.exe" in the folder, highlight it and click "Open" (or just double-click it).
If the Premium Data Converter has been installed elsewhere, navigate to the folder on your chosen installation path to find "Premium Data Converter.exe". [Next]
9. In the "Add Arguments (optional)" box, enter the following text: autoupdate=1 autoclose=1 [Next]
10. Summary - click "Finish".
Alternatively, the Scheduled Task can instead call a batch file that first does an update in the Premium Data
program and once finished runs the Premium Data Converter. Click on "Sample Batch File" below for an example.
Sample Batch File
Hide
echo off
c:
cd /trading applications/bin
dataupdater.exe autoupdate=1 autoclose=1
cd /Program Files/Premium Data Converter
"Premium Data Converter.exe" autorun=1 autoclose=1
echo on
Why doesn't the Converter have an option to clear the existing contents of the Destination
Folder?
Because the Destination Folder path is freely set by the user rather than mandated by the Converter.
Therefore an option to automatically empty or delete the existing Destination Folder is dangerous (important files
that are completely un-related to the Converter could be inadvertently deleted).
Users may wish to regularly clear the existing contents before doing a conversion so as to prevent redundant
symbols from accumulating. An example "batch file" to perform this task can be found below. Please take care with any
process you implement that automatically removes things from your computer!
Sample Batch File
Hide
echo off
del "C:\<your Premium Data Converter Destination Folder path>\*.*" /Q
c:
cd /Program Files/Premium Data Converter
"Premium Data Converter.exe" autorun=1 autoclose=1
echo on
Where can I find the market names that correspond to the symbols in my ascii output?
Please see the information under Destination Folder.
If I elect to show 5 decimal places, a stock price that should be exactly 12.55 comes out as 12.55001. What causes this lack of precision?
The MS data format uses the single precision (32 bit) floating-point system to represent numbers in binary form. This method can only be precise to 6 or 7 significant digits.
Where can I get the Premium Data converter?
You can download the installer from our Downloads area.
If you do not have a Premium Data username you can register for a no-obligation 3 week free trial to one of our data services to get access to our Downloads area.
How can I get the latest version?
The current version and release date are listed at the top of this page. To upgrade, simply download a new installer from our Downloads area and run it.
Do you have a question that's not covered here?
Send an email to
.
* MetaStock™ is a registered trademark of Equis International, Inc.
|