| chisqSmallN {semTools} | R Documentation |
Calculate k-factor correction for chi-squared model-fit test statistic to adjust for small sample size.
chisqSmallN(fit0, fit1 = NULL, ...)
fit0 |
The lavaan model object provided after running the |
fit1 |
Optional additional lavaan model, in which |
... |
Additional arguments to the |
The k-factor correction (Nevitt & Hancock, 2004) is a global fit index which can be computed by:
kc = 1 - \frac{2 \times P + 4 \times K + 5}{6 \times N}
where N is the sample size when using normal likelihood, or N - 1 when using likelihood = 'wishart'.
A numeric vector including the unadjusted (naive) chi-squared test statistic, the k-factor correction, the corrected test statistic, the df for the test, and the p value for the test under the null hypothesis that the model fits perfectly (or that the 2 models have equivalent fit).
Terrence D. Jorgensen (University of Amsterdam; TJorgensen314@gmail.com)
Nevitt, J., & Hancock, G. R. (2004). Evaluating small sample approaches for model test statistics in structural equation modeling. Multivariate Behavioral Research, 39(3), 439-478. doi:10.1207/S15327906MBR3903_3
HS.model <- '
visual =~ x1 + b1*x2 + x3
textual =~ x4 + b2*x5 + x6
speed =~ x7 + b3*x8 + x9
'
fit1 <- cfa(HS.model, data = HolzingerSwineford1939)
## test a single model (implicitly compared to a saturated model)
chisqSmallN(fit1)
## fit a more constrained model
fit0 <- cfa(HS.model, data = HolzingerSwineford1939,
orthogonal = TRUE)
## compare 2 models
chisqSmallN(fit1, fit0)