R/is_colour_vector.R

Defines functions is_colour_vector

#' @importFrom grDevices colours
is_colour_vector <- function(col) {
  all(col %in% grDevices::colours() | grepl("^#[0-9a-fA-F]{6}$|^#[0-9a-fA-F]{8}$", col))
}

is_color_vector <- is_colour_vector

Try the dynplot package in your browser

Any scripts or data that you put into this service are public.

dynplot documentation built on Dec. 11, 2021, 9:33 a.m.