Learn R Programming

lavaanExtra (version 0.2.1)

nice_modindices: Extract relevant modification indices along item labels

Description

Extract relevant modification indices along item labels, with a similarity score provided to help guide decision-making for removing redundant items with high covariance.

Usage

nice_modindices(fit, labels = NULL, method = "lcs", sort = TRUE, ...)

Value

A dataframe, including the outcome ("lhs"), predictor ("rhs"), standardized regression coefficient ("std.all"), corresponding p-value, as well as the unstandardized regression coefficient ("est") and its confidence interval ("ci.lower", "ci.upper").

Arguments

fit

lavaan fit object to extract modification indices from

labels

Dataframe of labels. If the original data frame is provided, and that it contains labelled variables, will automatically attempt to extract the correct labels from the dataframe.

method

Method for distance calculation from stringdist::stringsim. Defaults to "lcs".

sort

Logical. If TRUE, sort the output using the values of the modification index values. Higher values appear first. Defaults to TRUE.

...

Arguments to be passed to lavaan::modindices