Description Usage Arguments Value Examples
View source: R/inherit_category.R
This function creates an individual weighting category with known marginal
probabilities (E.g., age group, eye color.), but unlike
creates them from existing data instead of being directly assigned. One or more
of these are built and fed into
inherit_category(name, from, weight)
Name given to weighting category, character. Must have exact match in the column names of data you intend to weight as well as the existing data from where targets are being pulled.
Existing data frame from where targets will be pulled.
Optionally provide an existing weight variable to calculate weighted target proportions. Omit if unweighted target proportions are desired.
tibble with special class
1 2 3 4 5 6 7 8 9 10 11 12
data(demo_data) inherit_category( name = "EyeColor", from = demo_data ) inherit_category( name = "BirthYear", from = demo_data, weight = prev_weight )
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.