help for opendf version 2.0.2 (28 August 2024)

opendf -- Stata package to work with Open Data Format files (ODF/.zip). Provides import end export filters for ODF files and a function to display metadata.

Functions and Syntax

Main Functions

Read data

opendf read input [,rowrange() colrange() clear save() replace verbose]

Write data

opendf write output [,input() languages() variables() verbose]

Display metadata of dataset or variable

opendf docu [ varname, languages()]

Functions to Install/Remove Python for Opendf Package

Download a portable Python version for a working Python integration in Stata for the opendf package.

opendf installpython [, version() location()]

Delete the portable Python version installed with opendf installpython.

opendf removepython [, version() location()]

Functions for Data Providers

Build a Stata dataset (.dta) with metadata from the opendf specification from csv files containing meta data for survey data.

opendf csv2dta , csv_loc() [rowrange([start][:end]) colrange([start][:end])} clear save() replace verbose]

Write data in open data format (.zip) from csv files containing meta data for survey data.

opendf csv2zip, output() [input() variables_arg() export_data() verbose]

Write four CSV-files with data and meta data from Stata ODF dataset.

opendf dta2csv, output_dir() [languages() input()]

Write four CSV-files with data and meta data from ODF zip-file.

opendf zip2csv, input_zip() output_dir() languages() [verbose]

Description

opendf read -- builds a Stata dataset (.dta) from open data format dataset (.zip)

opendf write -- Saves data in the opendf-format as opendf-zip folder containing a csv(data) and a xml(metadate) file.

opendf docu -- Display information about the dataset or a variable.

opendf installpython -- Downloads a portable Python installation to some directory (default: Stata ado plus folder) on your computer.

opendf removepython -- Removes portable Python that was installed with opendf installpython.

opendf csv2dta -- Build a Stata dataset (.dta) with metadata from the opendf specification from four csv files containing meta data for survey data.

opendf csv2zip -- Write data in open data format (.zip) from four csv files containing meta data for survey data.

opendf dta2csv -- Write four CSV-files containing meta data for survey data from Stata ODF dataset.

opendf zip2csv -- Write four CSV-files containing meta data for survey data from ODF zip-file.

Remarks

The opendf commands in the opendf package from the Open Data Format Project are written to assist with survey data files in the open data format (ODF/.zip).

Due to cross-plattform compability of the Open Data Format some Stata-specific features are not supported by the ODF.

There are no value label names in the ODF. Therefore, value label names are lost when a datset is written to ODF. Value labels reveice generic names when an ODF file is read in Stata.

Extended missings for numeric variables (.a, .b, ..., .z) are not available in ODF specification. Therefore, extended missings are converted to ordinary missings (.)

Value Labels of extended missings er not written to ODF file.

Author

Tom Hartl (thartl@diw.de), Deutsches Institut für Wirtschaftsforschung Berlin.

Also see

Help: opendf read, opendf write, opendf docu, opendf installPython, opendf removePython opendf csv2dta, opendf csv2zip, opendf dta2csv, opendf zip2csv