c4a_scores: Get information from a cols4all palette

View source: R/c4a_scores.R

c4a_scoresR Documentation

Get information from a cols4all palette

Description

Get information from a cols4all palette

Usage

c4a_scores(
  palette = NULL,
  type = NULL,
  series = NULL,
  n = NA,
  no.match = c("message", "error", "null"),
  verbose = TRUE
)

Arguments

palette

name of the palette

type

type of palettes (in case palette is not specified)

series

series name (in case palette is not specified)

n

number of colors

no.match

what happens is no match is found? Options: "message": a message is thrown with suggestions, "error": an error is thrown, "null": NULL is returned

verbose

should messages be printed?

Value

list with the following items: name, series, fullname, type, palette (colors), na (color), nmax, and reverse. The latter is TRUE when there is a "-" prefix before the palette name.

Examples

c4a_scores("blues3")

pals = c4a_palettes(type = "cat")
scores_cat7 = t(sapply(pals, c4a_scores, n = 7))

head(scores_cat7)

cols4all documentation built on Oct. 17, 2024, 1:07 a.m.