schola_barplot | R Documentation |
schola_barplot(
.data,
vars,
group,
dict = dict_from_data(.data),
escape_level = "nevĂm",
n_breaks = 11,
desc = TRUE,
labels = TRUE,
min_label_width = 0.09,
absolute_counts = TRUE,
fill_cols = NULL,
fill_labels = waiver(),
facet_label_wrap = 115,
reverse = FALSE,
order_by = "chi-square differences",
drop = FALSE,
drop_na = TRUE,
show.legend = TRUE,
...
)
.data |
data with items and group variable |
vars |
vector of items, supports |
group |
group variable used to split the results, have to be logical,
where |
dict |
item code-label dictionary, if none provided, those are derived from the data. |
escape_level |
character, level of item response considered as NA |
n_breaks |
number of breaks displayed at x-axis, outer labels are automatically aligned to face inward. Defaults to 11, which results in 10% wide breaks. |
desc |
sor items in descending order? |
labels |
draw labels? |
min_label_width |
smallest percentage (0-1) to display in the plot, proportions larger than this value are shown, smaller are not. |
absolute_counts |
draw labels and absolute counts in parentheses? |
fill_cols |
colors to be used for item categories, defaults to NULL, meaning standard RdYlBu palette will be used |
fill_labels |
character vector or function taking breaks and returning labels for fill aesthetic |
facet_label_wrap |
width of facet label to wrap |
reverse |
if TRUE, reverse colors |
order_by |
how to order the items. chi-square differences (default) computes chi-square test for every item and sort them by largest X2 statistic to smallest (if desc = TRUE) |
drop |
Drop unobserved levels form the legend? Defaults to |
drop_na |
Drop |
show.legend |
logical. Should this layer be included in the legends?
|
... |
Arguments passed on to
|
Object of class "gg", "ggplot".
Other Making charts:
flush_axis
,
plot_lollipop()
,
prepare_lollipop_data()
,
theme_schola()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.