assert | R Documentation |
Assert a vector meets important data-quality requirements.
assert_non_na(x, class_vector, proportion_minimum)
assert_non_na_and_unique(x, class_vector)
x |
Vector to inspect. Required. |
class_vector |
The required |
proportion_minimum |
The (inclusive) minimum proportion of the vector's elements that should meet the requirement. If missing, all elements must pass. |
requireNamespace("OuhscMunge")
OuhscMunge::assert_non_na(1:30, "integer")
## Not run:
OuhscMunge::assert_non_na(c(1:30, NA_integer_), "integer")
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.