Common SNAP color palettes.

snapalettes(palette = 1, n = NULL)

Arguments

palette

character or integer, name or index of color palette.

n

number of colors returned from palette. See details.

Value

a vector of hex colors.

Details

Obtain commonly used SNAP color palettes for styling plots. Palettes can be specified by name or index. By default, all colors are returned (n = NULL). If n is less than the number of colors in palette, the first n colors are returned.

Examples

snapalettes()
#> [1] "#386cb0" "#fdb462" "#7fc97f" "#ef3b2c" "#662506" "#a6cee3" "#fb9a99" #> [8] "#984ea3" "#ffff33"