saturation | R Documentation |
Generic function to control the saturation of a palette.
saturate(x, amount = 0.1, ...)
## Default S3 method:
saturate(x, amount = 0.1, ...)
## S3 method for class 'palette'
saturate(x, amount = 0.1, ...)
desaturate(x, amount = 0.1, ...)
## Default S3 method:
desaturate(x, amount = 0.1, ...)
## S3 method for class 'palette'
desaturate(x, amount = 0.1, ...)
x |
A vector of colors |
amount |
A numeric value to control the saturation of the palette |
... |
Additional arguments passed to other methods. Currently ignored. |
A palette vector with the saturation adjusted
saturate(palette(roygbiv))
desaturate(palette(roygbiv))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.