Description Usage Arguments Value Examples
Finds a color between those received as input in RGB palette
1 2 | rgb_weighted_mean(col1, col2, w1 = 0.5, smooth_factor = 2,
output = "hex")
|
col1 |
First color. Hexcode, c(r,g,b), color name as character and "color" class object are all supported. |
col2 |
Second color. Hexcode, c(r,g,b), color name as character and "color" class object are all supported. |
w1 |
Number between 0 and 1. Represents how similar the output will be to col1. Defaults to .5 |
smooth_factor |
Correction to prevent mixtures from appearing too dark, making the palette more related to human perception of color. Defaults to 2 |
output |
Format in which output will be returned. Use "hex" to get a hexcode. Use "color" for a "color" class object to be returned. Defaults to "hex" |
w2 |
Number between 0 and 1. Represents how similar the output will be to col2. Defaults to 1-w1 |
The corresponding hexcode or "color" class object.
1 2 | rgb_weighted_mean("red", "green", smooth_factor=1)
rgb_weighted_mean("red", "green", smooth_factor=7000)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.