Skip to content
All library documents

Reading Legacy MetaStock Data into Python

Article Quant Q&A · Author: curious

Summary

The document asks whether legacy MetaStock end-of-day files can be loaded directly into pandas. It describes the format as binary and notes that it is associated with several file types, but gives no decoding procedure or implementation details.

The accepted response says common Python libraries cannot read this legacy format directly, so the data would need conversion to text before import. It suggests obtaining the data through a Python-friendly provider as a simpler alternative. This is a brief, dated answer rather than a technical guide: it does not demonstrate conversion, compare providers in detail, or establish whether later tools support the format.

Key ideas

  • Legacy MetaStock data is stored in a binary format that is not directly readable by common Python libraries, according to the answer.
  • The proposed workaround is to convert the files to text before importing them into pandas.
  • The response suggests using a data provider with Python integration as an alternative.
  • The document offers no conversion example or evidence beyond the answerer's assertion.

Tags

Full text
# Loading metastock data into panda data frames


# Loading metastock data into panda data frames












Most paid end-of-day data packages are available in metastock format. For analytics purposes, it will be nice if one can read the metastock data and load them into Python panda data frames. Is it possible to do this today?

The metastock format I am referring to is the legacy (pre-12.0) MetaStock file format. It is a binary file format and originated from the Computrac file format. There are four files associated with the format: MASTER, EMASTER, XMASTER, FDAT, and F.MWD.

## Answer by Rehan (score 1, accepted)

https://quant.stackexchange.com/a/32760

The binary data from MetaStock cannot be directly read into a pandas dataframe, or for the matter of fact, into any python library commonly known. For this you would need to convert it into text and then import, which simply complicates the process.

The easier way to do this, would be to use Quandl - although it costs slightly higher than MetaStock, it ties in very well to Python, and you can import the requisite data in a jiffy.

Shown in full with attribution under the source's licence. Licence: CC BY-SA 4.0 (Stack Exchange)

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.