get_invareffsize: User-facing function to calculate all noninvariance effect...

Description Usage Arguments Examples

View source: R/get_invareffsize.R

Description

User-facing function to calculate all noninvariance effect size measures in Gunn et al. (2020)

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
get_invareffsize(
  dat,
  fit,
  model,
  nodewidth = 0.01,
  lowerLV = -5,
  upperLV = 5,
  lvname = NULL,
  writeRTF = FALSE
)

Arguments

dat

data frame of indicators

fit

outputted multi-group cfa lavaan object

model

inputted lavaan model syntax

nodewidth

space between nodes during quadrature approximation (default = .01)

lowerLV

lowest latent variable value evaluated (default = -5)

upperLV

greatest latent variable value evaluated (default = 5)

lvname

character to name outputted table and file.

writeRTF

logical argument to request automated outputting of reproducible table (defaults to FALSE)

Examples

1
2
3
4
5
dat <- HolzingerSwineford1939
dat$group[dat$school=="Pasteur"] = "Pasteur"
dat$group[dat$school=="Grant-White"] = "Grant-White"
HS.model <- '  visual =~ x1 + x2 + x3'
fit <- lavaan::cfa(HS.model, data = dat, group = "group")

jsakaluk/psyscores documentation built on Dec. 16, 2021, 6:50 p.m.