Description Usage Arguments Value See Also Examples
View source: R/univariateGraph.R
univariateGraph()
produces a univariate graph based on
the contents of the input data frame, which must be a mt_univariateSummary
object.
1 2 | univariateGraph(data, xLabel, yLabel, yType, yDigits, yRangeMode = "tozero",
barColor = "#BDDFF7", lineColor = "#000000")
|
data |
|
xLabel |
character string; |
yLabel |
character string; |
yType |
character string; |
yDigits |
non-negative integer value indicating the number of decimal
places to show for values of the |
yRangeMode |
character string; |
barColor |
character string; fill color for bars (valid color) |
lineColor |
character string; line color (valid color) |
A plot_ly
visualization of a
mt_univariateSummary
object, showing the distribution of a
binned variable x
overlayed with an aggregated summary statistic of a
variable y
.
1 2 3 4 5 6 7 8 9 10 11 12 13 | # numeric x logical y
x <- c(rnorm(5000, 100, 10), rep(as.numeric(NA), 500))
y <- runif(5500)
z <- univariateSummary(x, y < 0.50)
univariateGraph(z, "Random Normal", "Random Uniform", "pct", 1)
# numeric x continuous y
z <- univariateSummary(x, y*100, 2, numBins = 15)
univariateGraph(z, "Random Normal", "Random Uniform", "dlr", 0)
# character x continuous y
z <- univariateSummary(iris$Species, iris$Sepal.Length, 2)
univariateGraph(z, "Species", "Sepal Length", "int", 2)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.