Adds degrees to each colour's HSL hue, wrapping around the colour
wheel (%% 360). Generalizes the fixed hue offsets
palette_harmony() uses internally into a plain, arbitrary-angle
operation on an existing colour vector.
See also
Other color helpers:
color_alpha(),
color_greyscale(),
color_invert(),
color_jitter(),
color_lighten(),
color_mix(),
color_saturate()
Examples
color_rotate_hue("tomato", degrees = 180)
#> [1] "#47E3FF"
color_rotate_hue(palette_manual(index = 1), degrees = c(0, 30, 60, 90, 120))
#> [1] "#33658A" "#8692D8" "#3F2F58" "#2DF649" "#19F264"
draw(effect_swatch(color = color_rotate_hue("tomato", degrees = seq(0, 300, 60))))