Description Usage Arguments Details Value See Also Examples
Creates a data frame object of class mrp.table that contains counts
and proportions for the interactions between all demographic variables
specified by model. The resulting output is designed (and required)
for use in estimating cell predictions using the mrp_model
function.
1 |
model |
formula: A list object containing column names in
|
data |
A |
weights |
numeric: Optional vector of weights to use when calculating counts and proportions. |
If data is not provided, then the function will use a preset data file
created from the CPS Nov. 2012 voter survey.
The value passed to model must be a list object of column names in
data, and each must also be passed as a formula. For example, to
create a MRP table for the interaction between columns named ‘state’ and
‘sex’, the argument to model would be: list(~state, ~sex).
Additionally, the first name in this list will be used to group final
proportions by.
A data frame containing counts and proportions for all unique
interactions between the variables specified in model.
1 2 3 4 5 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.