R/gg_color_hue.R

Defines functions gg_color_hue

# #' @title Default \code{ggplot} color palette
# #' @description Generate default discrete \code{ggplot} color
# #' @param n the number of colors
gg_color_hue <- function(n) {
  hues <- seq(15, 375, length = n + 1)
  grDevices::hcl(h = hues, l = 65, c = 100)[1:n]
}

Try the loon.ggplot package in your browser

Any scripts or data that you put into this service are public.

loon.ggplot documentation built on May 29, 2024, 4:58 a.m.