PRIDITweight: Compute PRIDIT weights

View source: R/PRIDITweight.R

PRIDITweightR Documentation

Compute PRIDIT weights

Description

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.

Usage

PRIDITweight(ridit_data)

Arguments

ridit_data

A data frame returned by ridit: first column is the ID, remaining columns are ridit scores.

Value

A named numeric vector of PRIDIT weights, one per indicator column.

See Also

ridit, PRIDITscore, pridit

Examples

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)


pridit documentation built on May 31, 2026, 5:07 p.m.