This is a helper function that provides hex color codes for
jtools
, interactions
, and perhaps other packages.
get_colors(colors, num.colors = 1, reverse = FALSE, gradient = FALSE)
The name of the desired color class or a vector of colors. See details of jtools_colors.
How many colors should be returned? Default is 1.
Should the colors be returned in reverse order, compared to normal? Default is FALSE.
Return endpoints for a gradient? Default is FALSE. If TRUE,
num.colors
is ignored.