A simple red gradient colour scale that extends ggplot2::scale_*_gradient
.
Usage
scale_colour_gradient_red(low = "#FFFFFF", high = "#F21A00", ...)
scale_color_gradient_red(low = "#FFFFFF", high = "#F21A00", ...)
scale_fill_gradient_red(low = "#FFFFFF", high = "#F21A00", ...)
Arguments
- low, high
Colours for low and high ends of the gradient.
- ...
arguments to pass to
ggplot2::scale_*_gradient
Examples
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()