ggdensity | R Documentation |
Density Plot
ggdensity( data, col, fill = "steelblue", alpha = 0.5, summary_stats = FALSE, text_xpos = NULL, text_ypos = 0.04, text_sigfigs = Inf, ... )
data |
datafrmae |
col |
column (don't quote) |
fill |
geom_density fill color |
alpha |
geom_density alpha color |
summary_stats |
add text with summary stats to plot (boolean) |
text_xpos |
x position of summary stat text (numeric) |
text_ypos |
y position of summary stat text (numeric) |
text_sigfigs |
number of significant figures to write summary statistic to (numeric) |
... |
other geom_density aesthetics (e.g. linetype = "dashed") |
gglot
ggdensity(mtcars, mpg, summary = TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.