cloneVariable {eatGADS} | R Documentation |
Clone a variable.
Description
Clone a variable as part of a GADSdat
object.
Usage
cloneVariable(
GADSdat,
varName,
new_varName,
label_suffix = "",
checkVarName = TRUE
)
Arguments
GADSdat |
|
varName |
Name of the variable to be cloned. |
new_varName |
Name of the new variable. |
label_suffix |
Suffix added to variable label for the newly created variable in the |
checkVarName |
Logical. Should |
Details
The variable is simply duplicated and assigned a new name.
Value
Returns a GADSdat
.
Examples
# duplicate the variable schtype
pisa_new <- cloneVariable(pisa, varName = "schtype", new_varName = "schtype_new")
[Package eatGADS version 1.1.0 Index]