R/selector.R

Defines functions `[[.cpcinema` `[.cpcinema`

#' @export
`[.cpcinema` <- function(x, ...) {
  x <- NextMethod()
  new_palette(unclass(x), length(x), "discrete")
}

#' @export
`[[.cpcinema` <- function(x, ...) {
  x <- NextMethod()
  vec_cast(x, character())
}
JosiahParry/cpcinema documentation built on March 20, 2021, 12:04 a.m.