Arguments
file
A file name, ending in csv, xlsx or rds.
ignoreCase
In the use of this key, should we ignore
differences in capitalization of the "name_old" variable?
Sometimes there are inadvertent misspellings due to changes in
capitalization. Columns named "var01" and "Var01" and "VAR01"
probably should receive the same treatment, even if the key
has name_old equal to "Var01".
sep
Defaults are specified, don't change this unless you
know what you are doing. In wide keys, what separators are
used between values? This should be a named vector which
declares separators that are used in the key. In our defaults,
the separator for classes character, logical, integer, and
numeric is the pipe, "|", while for factor and ordered
variables, the separator may be either pipe or less than. Use
regular expressions in supplying separator values.
na.strings
Values in the value_new column which will be
treated as NA in the key. The defaults are ".", "", "\s"
(white space), "NA", and "N/A". These will prevent a new
value like "" or " " from being created, so if one intends to
insert white space, the na.strings vector must be specified.
...
additional arguments for read.csv or read.xlsx.
keynames
Don't use this unless you are very careful. In
our current scheme, the column names in a key should be
c("name_old", "name_new", "class_old", "class_new",
"value_old", "value_new", "missings", "recodes"). If your key
does not use those column names, it is necessary to provide
keynames in a format "our_name"="your_name". For example,
keynames = c(name_old = "oldvar", name_new = "newname", class_old =
"vartype", class_new = "class", value_old = "score", value_new
= "val")
.