Description Usage Arguments Details Value Author(s) See Also Examples
Calculate HTML colour code from a palette like ggplot2 uses.
| 1 | 
| n | Numeric value to determine size of palette. | 
| sub | Numeric vector with values within range from  | 
| h | Hue of the colour. Within range of a circle's degrees. | 
| c | Chroma of the colour. | 
| l | Luminance of the colour. Within range from  | 
| ... | Further arguments passed to function  | 
See ?hcl for explanation of h, c and l.
Returns a character vector containing HTML colour code of the
standard ggplot colour palette.
Sven E. Templer
hcl
| 1 2 3 4 5 6 7 8 9 10 11 | #
# Plot some palettes:
par(mfrow = c(3,1), mai = c(.1,.1,1,.1))
p <- matrix(1:10, 10)
image(p, col = gghcl(5), axes = FALSE, main ="gghcl(5)")
image(p, col = gghcl(10), axes = FALSE, main = "gghcl(10)")
image(p, col = gghcl(10, 1:5), axes = FALSE, main ="gghcl(10, 1:5)")
# dev.off() # to reset \code{par}
#
 | 
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.