Description Usage Arguments Value Warning Examples
...
1 2 3 4 5 6 | plot_poll(vote = c(cdu = 0.33, spd = 0.2, fdp = 0.11, linke = 0.09,
gruene = 0.09, afd = 0.12, sonstige = 0.05), order = "alphabetical",
sample_confidence_bounds = TRUE, sample_n = 1000, n_draw = 10000,
show_quantiles = c(0.05, 0.95), round = 1, xlab = "Party",
ylab = "Voteshare", title = "Title", subtitle = "Subtitle",
caption = "Caption", theme_ipsum = FALSE, grid = "Y")
|
vote |
A labeled party vote share vector. |
order |
Method to order parties (Default is "alphabetical"; also takes "descending" and "ascending" as well as manual specification of party vector) |
sample_confidence_bounds |
Logical T/F: add empirical dirichlet quantiles |
sample_n |
The number of observations in the poll sample. |
n_draw |
How many samples to draw from the dirichlet distribution. |
show_quantiles |
Vector of quantiles/confidence boundaries to calculate. |
round |
Round to k decimals after comma |
xlab |
x-label string |
ylab |
y-label string |
title |
title string |
subtitle |
subtitle string |
caption |
caption string |
theme_ipsum |
Pre-applies nice theme from the hrbrthemes-package.(Attention: possible font-issues when Roboto font is not installed on your computer.) |
grid |
(Applies only if theme_ipsum == T) Add a grid (options: "none","Y") |
A data frame containing n
rows of samples for each party.
Do not operate heavy machinery within 8 hours of using this function.
1 | sample_dirichlet_quantiles(vote = c(cdu = 0.33,....
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.