plot_scatter | R Documentation |
Create a scatter plot to display the relationship between two continuous variables.
This is essentially a wrapper for ggplot2::geom_point()
.
plot_scatter(
data,
x,
y,
color_by,
smooth = FALSE,
range = c(0.01, 0.99),
title = "",
aspect_ratio = 1
)
data |
A data frame. |
x |
. |
y |
. |
color_by |
Column metadata field(s) or feature(s) to color by. |
smooth |
A logical scalar. Smooth values. Helps to visualize expression patterns in a plot with many overlapping points. |
range |
A vector of 2 values indicating the minimum and maximum percentiles for the color range. Helps to visualize expression patterns when extreme outliers are present. For example, |
title |
Plot title. |
aspect_ratio |
Aspect ratio of the panel. |
A ggplot object.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.