powered by
Check whether a character string is a valid color specification.
is_color(x, null_ok = FALSE)
A 'logical' vector of the same length as argument x.
x
'character' vector. color specification
'logical' flag. If set to TRUE, x may also be NULL.
TRUE
NULL
J.C. Fisher, U.S. Geological Survey, Idaho Water Science Center
is_color(c("red", "zzz", "#FFFFFF", "#7FAF1B111"))
Run the code above in your browser using DataLab