Description Usage Arguments Value Examples
Generate color code
1 | generate_color_list(color, number, alpha = 1, constantColor = F)
|
color |
Colors like c('red', 'blue', '#6181BD') or a RColorBrewer color set like "BrBG" "PiYG" "PRGn" "PuOr" "RdBu" "RdGy" "RdYlBu" "RdYlGn" "Spectral" "Accent" "Dark2" "Paired" "Pastel1" "Pastel2" "Set1" "Set2" "Set3" "Blues" "BuGn" "BuPu" "GnBu" "Greens" "Greys" "Oranges" "OrRd" "PuBu" "PuBuGn" "PuRd" "Purples" "RdPu" "Reds" "YlGn" "YlGnBu" "YlOrBr" "YlOrRd" (check http://www.sthda.com/english/wiki/colors-in-r for more). |
number |
Number of colors to return. |
alpha |
Generate an alpha transparency values for return colors. 0 means fully transparent and 1 means opaque. Default 1. |
A color vector
1 2 3 4 | generate_color_list('red', 5)
generate_color_list(c('green', 'red'), 5)
generate_color_list(c('green', 'red'), 5, alpha=0.5)
generate_color_list("Set3", 5)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.