scale_colour_gradient_red | R Documentation |
A simple red gradient colour scale that extends ggplot2::scale_*_gradient
.
scale_colour_gradient_red(low = "#FFFFFF", high = "#F21A00", ...)
scale_color_gradient_red(low = "#FFFFFF", high = "#F21A00", ...)
scale_fill_gradient_red(low = "#FFFFFF", high = "#F21A00", ...)
low, high |
Colours for low and high ends of the gradient. |
... |
arguments to pass to |
df <- data.frame(
x = runif(100),
y = runif(100),
z1 = rnorm(100),
z2 = abs(rnorm(100))
)
ggplot2::ggplot(df, ggplot2::aes(x, y)) +
ggplot2::geom_point(
ggplot2::aes(fill = z2),
size = 3,
shape = 21) +
scale_fill_gradient_red() +
theme_neat()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.