Stata .dta file reader.
Provides methods to return the metadata of a Stata .dta file and a generator for the data itself.
Parameters : | file : file-like
missing_values : bool
encoding : string, optional
|
---|
See also
statsmodels.lib.io.genfromdta
Notes
This is known only to work on file formats 113 (Stata 8/9), 114 (Stata 10/11), and 115 (Stata 12). Needs to be tested on older versions. Known not to work on format 104, 108. If you have the documentation for older formats, please contact the developers.
For more information about the .dta format see http://www.stata.com/help.cgi?dta http://www.stata.com/help.cgi?dta_113
Methods
dataset([as_dict]) | Returns a Python generator object for iterating over the dataset. |
file_format() | Returns the file format. |
file_headers() | Returns all .dta file headers. |
file_label() | Returns the dataset’s label. |
file_timestamp() | Returns the date and time Stata recorded on last file save. |
variables() | Returns a list of the dataset’s StataVariables objects. |
Attributes
DTYPE_MAP | |
MISSING_VALUES | |
TYPE_MAP | list() -> new empty list |
i | int(x=0) -> int or long |