chk_chr | R Documentation |
Checks if character scalar using
is.character(x) && length(x) == 1L
chk_chr(x, x_name = NULL)
vld_chr(x)
x |
The object to check. |
x_name |
A string of the name of object x or NULL. |
The chk_
function throws an informative error if the test fails or
returns the original object if successful so it can used in pipes.
The vld_
function returns a flag indicating whether the test was met.
Other deprecated:
chk_dbl()
,
chk_deprecated
,
chk_wnum()
chk_chr("a")
try(chk_chr(1))
# vld_chr
vld_chr("")
vld_chr("a")
vld_chr(NA_character_)
vld_chr(c("a", "b"))
vld_chr(1)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.