| olink_color_gradient | R Documentation |
Olink color scale for continuous ggplots
olink_color_gradient(..., alpha = 1, coloroption = NULL)
... |
Optional. Additional arguments to pass to
|
alpha |
transparency (optional) |
coloroption |
string, one or more of the following: c("red", "orange", "yellow", "green", "teal", "turquoise", "lightblue", "darkblue", "purple", "pink") |
No return value, called for side effects
ggplot2::diamonds |>
dplyr::filter(
.data[["x"]] > 5
& .data[["x"]] < 6
& .data[["y"]] > 5
& .data[["y"]] < 6
) |>
dplyr::mutate(
diff = sqrt(
x = abs(
x = .data[["x"]] - .data[["y"]]
)
) * sign(
x = .data[["x"]] - .data[["y"]]
)
) |>
ggplot2::ggplot(
mapping = ggplot2::aes(
x = .data[["x"]],
y = .data[["y"]],
colour = .data[["diff"]]
)
) +
ggplot2::geom_point() +
ggplot2::theme_bw() +
OlinkAnalyze::olink_color_gradient()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.