Description Usage Arguments Value Examples
Plots the mean values of a dependent variable at different values of nominal or ordinal independent variable. Makes use of survey package's svy
1 | plotmeansC(data, function1 = NULL, function2 = NULL, function3, w = 1, ...)
|
data |
A dataset (e.g. gss, nes, states, or world) or design dataset (e.g. gssD, nesD, statesD, or worldD) |
function1 |
A function in the form of ~ depvar |
function2 |
A formula in the form of ~ indepvar |
function3 |
A formula in the form of depvar ~ indepvar |
w |
Weights, in the form ~ weightvar (optional, not needed if you use a design dataset) |
... |
Additonal arguments passed to gplots package's |
No return
1 2 3 4 5 6 7 8 9 10 11 | library(poliscidata)
plotmeansC(nesD, ~ft_hclinton, ~pid_x, ft_hclinton~pid_x,
xlab="Party Identification", ylab="Ratings of Hillary Clinton",
main="Ratings of Hillary Clinton by Party Identification")
plotmeansC(nes,~envir,~pid_3,envir~pid_3,w=~wt,
xlab="Party Identification",
ylab="Percent Pro-Environment",
main="Percentage Favoring Environment over Jobs,\n by Party ID")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.