Description Usage Arguments Details Value Examples
View source: R/GraphFunctions.R
compare.toplines
creates a scatter plot with time on the x-axis
1 | compare.toplines(varlist, vartext = NULL, mulaw, sortResponse, remove = NULL)
|
varlist |
a vector of quoted variable names |
vartext |
a character vector of text which should be used to describe the variables |
mulaw |
the relevant integ file |
sortResponse |
The response category in the topline tables by which to sort the vartext |
remove |
an optional vector of values to remove from the topline table, supplied to the remove argument in make.topline() |
This function takes a list of variables, makes toplines of them, and plots the toplines in a graph with one question per row and dots for the values of each question response.
A ggplot object.
1 2 3 4 5 | compare.toplines(varlist = c("d38", "d55", "d91", "d59", "d92"),
mulaw = demprimary,
vartext = c("Joe Biden", "Elizabeth Warren", "Kamala Harris", "Bernie Sanders", "Pete Buttigieg"),
sortResponse = "Favorable",
remove = c("don't know", "refused"))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.