Function is necessary for eatRep
and eatModel
as well
and therefore exported to namespace.
Usage
existsBackgroundVariables (dat, variable, warnIfMissing = FALSE,
stopIfMissingOnVars = NULL)
Arguments
- dat
A data frame
- variable
column number or variable name
- warnIfMissing
Logical: gives a warning if the variable contains missing values
- stopIfMissingOnVars
Character vector of variable names. Only for these variables, warnings as raised
through warnIfMissing = TRUE
are turned into errors.
Value
a structured list of variable names
Examples
data(mtcars)
existsBackgroundVariables(mtcars, 2:4)
#> [1] "cyl" "disp" "hp"