Description Usage Arguments Value
This function identifies specifically columns with dummy variables (only 0 and 1) from all other column types. 1.0 as single value returns TRUE, which is a matter of print formatting rather of type.
1 | is.dummy(x)
|
x |
the vector to be tested, use 'sapply(x, is.wholenumber)' for a data frame. Strict testing using 'vapply(x, FUN = is.dummy, FUN.VALUE = logical(1)' |
A logical vector returning TRUE for column(s) that only contain 0 and/or 1
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.