Description Usage Arguments Value Examples
compare_distributions
Compare an empirical data distribution to fitted distributions using pdf, cdf, qq, and pp plots.
1 2 | compare_distributions(data, limits = NULL, quantity = "Data",
title = NULL)
|
data |
data.frame or matrix; The first column is the empirical data, the others being the data from the theoretical distribution e.g. gene means or library sizes |
quantity |
string; Name of thing being compared - used in the axis labels |
limits; |
passed to scale_x_log10 "A numeric vector of length two providing limits of the scale.". Defaults to empirical range of the data. |
A ggplot2 object of pdf, cdf, qq, and pp plots.
1 2 3 4 | fake_data <- data.frame(data1 = rlnorm(n = 500, meanlog = 0, sdlog = 1), # would usually empirical data
data2 = rlnorm(n = 500, meanlog = 0, sdlog = 1.5),
data3 = rlnorm(n = 500, meanlog = 0.5, sdlog = 1))
compare_distributions(fake_data)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.