| PRIDITweight | R Documentation |
Computes the PRIDIT weight vector from a ridit-scored data frame. Weights
are the loadings of the first principal component of the ridit matrix,
scaled by the column norms of that matrix. The sign of the weight vector
is arbitrary (a property of PCA); pass the result to pridit
rather than using this function directly if automatic sign correction is
desired.
PRIDITweight(ridit_data)
ridit_data |
A data frame returned by |
A named numeric vector of PRIDIT weights, one per indicator column.
ridit, PRIDITscore, pridit
dat <- data.frame(
id = c("A", "B", "C", "D", "E"),
x1 = c(0.90, 0.85, 0.89, 1.00, 0.89),
x2 = c(0.99, 0.92, 0.90, 1.00, 0.93)
)
rs <- ridit(dat)
PRIDITweight(rs)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.