PartInv_old: Evaluate partial measurement invariance using Millsap &...

View source: R/deprec-PartInv.R

PartInv_oldR Documentation

Evaluate partial measurement invariance using Millsap & Kwok's (2004) approach

Description

Evaluate partial measurement invariance using Millsap & Kwok's (2004) approach

Usage

PartInv_old(
  propsel,
  cut_z = NULL,
  kappa_r,
  kappa_f = kappa_r,
  phi_r,
  phi_f = phi_r,
  lambda_r,
  lambda_f = lambda_r,
  Theta_r,
  Theta_f = Theta_r,
  tau_r,
  tau_f = tau_r,
  pmix_ref = 0.5,
  plot_contour = TRUE,
  labels = c("Reference group", "Focal group"),
  ...
)

Arguments

propsel

proportion of selection. If missing, computed using cut_z.

cut_z

prespecified cutoff score on the observed composite. This argument is ignored when propsel has input.

kappa_r

latent factor mean for the reference group.

kappa_f

(optional) latent factor mean for the focal group; if no input, set equal to kappa_r.

phi_r

latent factor variance for the reference group.

phi_f

(optional) latent factor variance for the focal group; if no input, set equal to phi_r.

lambda_r

a vector of factor loadings for the reference group.

lambda_f

(optional) a vector of factor loadings for the focal group; if no input, set equal to lambda_r.

Theta_r

a matrix of the unique factor variances and covariances for the reference group.

Theta_f

(optional) a matrix of the unique factor variances and covariances for the focal group; if no input, set equal to Theta_r.

tau_r

a vector of measurement intercepts for the reference group.

tau_f

(optional) a vector of measurement intercepts for the focal group; if no input, set equal to tau_r.

pmix_ref

Proportion of the reference group; default to 0.5 (i.e., two populations have equal size).

plot_contour

logical; whether the contour of the two populations should be plotted; default to TRUE.

labels

a character vector with two elements to label the reference and the focal group on the graph.

...

other arguments passed to the contour function.

Value

a list of four elements and a plot if plot_contour == TRUE. The four elements are

propsel

echo the same argument as input

cutpt_xi

cut point on the latent scale (xi)

cutpt_z

cut point on the observed scale (Z)

summary

A 8 x 2 table, with columns representing the reference and the focal groups, and the rows represent probabilities of true positive (A), false positive (B), true negative (C), false negative (D); proportion selected, success ratio, sensitivity, and specificity.

Examples

PartInv(.25, kappa_r = 0.5, kappa_f = 0, phi_r = 1,
        lambda_r = c(.3, .5, .9, .7), tau_r = c(.225, .025, .010, .240),
        Theta_r = diag(.96, 4), labels = c("female", "male"))

claycantrell/PartInvShinyUI documentation built on March 29, 2022, 9:49 a.m.