qbin_barplot | R Documentation |
qbin_barplot()
shows the median or mean for each quantile bin, thereby focusing on
the expected value per qbin()
.
For a conditional plot, see cond_barplot()
.
qbin_barplot(
data,
x = NULL,
n = 100,
min_bin_size = NULL,
overlap = NULL,
ncols = NULL,
fill = "#2f4f4f",
type = c("median", "mean"),
...
)
table_plot(data, x = NULL, n = 100, ncols = ncol(data), fill = "#555555", ...)
data |
a |
x |
|
n |
|
min_bin_size |
|
overlap |
|
ncols |
The number of column to be used in the layout. |
fill |
The color to use for the bars. |
type |
The type of statistic to use for the bars. |
... |
Additional arguments to pass to the plot functions |
The table_plot
is a specific form of qbin_barplot
with ncols
set to ncol(data)
.
A list
of ggplot objects.
Other qbin plotting functions:
qbin_boxplot()
,
qbin_heatmap()
,
qbin_lineplot()
data("diamonds", package="ggplot2")
table_plot(diamonds[c(1:4, 7)], "carat")
qbin_barplot(iris, "Sepal.Length", n = 12)
table_plot(iris, "Sepal.Length", n=12)
table_plot(
iris,
x = "Sepal.Length",
min_bin_size=20,
overlap=TRUE
)
if (require(palmerpenguins)) {
table_plot(penguins[1:7], "body_mass_g", 19)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.