View source: R/colorgradient.x.R
colorgradient.x | R Documentation |
Color gradient for continuous variable
colorgradient.x(
x,
symmetric = FALSE,
lo.col = "#0290EE",
mid.col = "#1A1A1A",
hi.col = "#FFBD4F",
space = "Lab"
)
x |
Float, vector |
symmetric |
Logical: If TRUE, make symmetric gradient between
|
lo.col |
Low color |
mid.col |
Middle color |
hi.col |
High color |
space |
Character: "rgb" or "Lab". Default = "Lab" |
E.D. Gennatas
## Not run:
x <- seq(-10, 10, length.out = 51)
previewcolor(colorgradient.x(x))
x <- sort(rnorm(40))
previewcolor(colorgradient.x(x, mid.col = "white"))
# Notice how most values are near zero therefore almost white
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.