SAMHDA distributes data files in the following formats: SAS, SPSS, Stata, ASCII, tab-delimited, and R. ASCII data files can be downloaded with their accompanying SAS, SPSS, or Stata setup files.
SAS transport files are generated by the SAS XPORT (for studies with older release dates) and SAS CPORT (for studies with newer release dates) procedures. Both types of files contain specially formatted SAS data sets, which have variable labels as well as data. SAMHDA's SAS CPORT files include SAS format catalogs with value labels. SAMHDA also supplies a SAS supplemental syntax file that provides missing value recodes.
SAS CPORT files should be imported into SAS with the SAS CIMPORT procedure. See "FAQs: Data Formats and Files" for additional information.
Because SAS has an engine that reads SAS XPORT files, these files can be read by any SAS command that can read an ordinary SAS data set, such as the SAS set statement or the SAS FREQ procedure. SAS XPORT files can also be converted to standard SAS data sets with the SAS COPY procedure.
SAMHDA distributes two types of SPSS data files:
- SPSS .sav files written by the SPSS save command
- SPSS portable files written by the SPSS export command
Both types of data files include variable labels and usually include value labels and missing value definitions.
Use the SPSS "get" command to load SPSS .sav files into SPSS. Use the SPSS "import" command to read SPSS portable files into SPSS.
Stata data files should be loaded using the Stata "use" command.
Use the R "load ()" command to load R .rda files into R. For example, if your downloaded data file, 32722-0001-Data.rda is located at D:/Downloads/32722/DS0001, then use load("D:/Downloads/32722/DS0001/32722-0001-Data.rda").