| flip | R Documentation |
Toggle boolean values in a vector.
flip(x)
x |
A CppVector object of type boolean. |
Sets TRUE to FALSE and FALSE to TRUE.
Invisibly returns NULL.
cpp_vector.
v <- cpp_vector(c(TRUE, TRUE, FALSE))
v
# TRUE TRUE FALSE
flip(v)
v
# FALSE FALSE TRUE
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.