palette_okabe_ito {ggokabeito} | R Documentation |
Okabe-Ito Palette
Description
palette_okabe_ito()
is a wrapper around palette.colors()
that returns the
Okabe-Ito palette in R 4.0.0 or greater. palette_okabe_ito()
returns an
unnamed vector of colors for better use with ggplot2. Additionally, black is
the last color returned by palette_okabe_ito()
when 9 colors are needed
instead of the first, as in palette.colors()
.
Usage
palette_okabe_ito(order = 1:9, alpha = NULL, recycle = FALSE)
Arguments
order |
A numeric vector, the order of the colors |
alpha |
an alpha-transparency level in the range [0,1] (0 means transparent and 1 means opaque). |
recycle |
logical indicating what happens in case |
Value
A character vector of hex codes
Examples
palette_okabe_ito()
palette_okabe_ito(order = c(2, 3, 5), alpha = 0.9)
[Package ggokabeito version 0.1.0 Index]