readMicrodata {sdcMicro} | R Documentation |
readMicrodata
Description
reads data from various formats into R. Used in sdcApp
.
Usage
readMicrodata(
path,
type,
convertCharToFac = TRUE,
drop_all_missings = TRUE,
...
)
Arguments
path |
a file path |
type |
which format does the file have. currently allowed values are
|
convertCharToFac |
(logical) if TRUE, all character vectors are automatically converted to factors |
drop_all_missings |
(logical) if TRUE, all variables that contain NA-values only will be dropped |
... |
additional parameters. Currently used only if |
Value
a data.frame or an object of class 'simple.error'. If a stata file was read in, the resulting data.frame
has an additional attribute lab
in which variable and value labels are stored.
Note
if type
is either 'sas'
, 'spss'
or 'stata'
, values read in as NaN
will be converted to NA
.
Author(s)
Bernhard Meindl
[Package sdcMicro version 5.7.8 Index]