Learn R Programming

RcmdrMisc (version 2.10.2)

readSAS: Read a SAS b7dat Data Set

Description

Read a SAS b7dat Data Set

Usage

readSAS(file, rownames = FALSE, stringsAsFactors = FALSE)

Value

a data frame.

Arguments

file

path to a SAS b7dat file.

rownames

if TRUE (the default is FALSE), the first column in the data set contains row names (which must be unique---i.e., no duplicates).

stringsAsFactors

if TRUE (the default is FALSE) then columns containing character data are converted to factors.

Author

John Fox

Details

readSAS reads a SAS ``b7dat'' data set, stored in a file of type .sas7bdat, into an R data frame; it provides a front end to the read_sas function in the haven package.

See Also