plot_groupedbar {daltoolbox} | R Documentation |
plot grouped bar
Description
plot grouped bar
Usage
plot_groupedbar(data, label_x = "", label_y = "", colors = NULL, alpha = 1)
Arguments
data |
data.frame contain x, value, and variable |
label_x |
x-axis label |
label_y |
y-axis label |
colors |
color vector |
alpha |
level of transparency |
Value
ggplot graphic
Examples
data <- iris |> dplyr::group_by(Species) |>
dplyr::summarize(Sepal.Length=mean(Sepal.Length), Sepal.Width=mean(Sepal.Width))
grf <- plot_groupedbar(data, colors=c("blue", "red"))
plot(grf)
[Package daltoolbox version 1.0.767 Index]