fade | R Documentation |
fade
provides the name of a semi-transparent R colour after passing the name of a base colour or colours (e.g. "blue") and the degree of opacity desired.
fade(colors, alpha)
|
is a character string of colour names to which transparency should be added. |
|
is a numeric vector specifying the desired opactity for each colour in |
The function returns a string containing the hexidecimal colour code and is then easily used as the colour to use in standard R plot commands.
newColour <- fade(c("blue", "green", "purple"), c(50, 100, 200))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.