| resolve_contrast_weights | R Documentation |
Expands a (possibly level-named or level-length) numeric weight vector into a full vector over all group levels in factor order, validating that it references known levels, sums to zero and is not trivially zero.
resolve_contrast_weights(x, orig_levels)
x |
Numeric weight vector, either named by group levels (missing levels are
filled with |
orig_levels |
Character vector of the group factor levels (in order). |
A numeric vector of length length(orig_levels) summing to zero.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.