semmcci: Monte Carlo Confidence Intervals in Structural Equation Modeling
Ivan Jacob Agaloos Pesigan
2024-10-22
Source:vignettes/semmcci.Rmd
semmcci.Rmd
Installation
You can install the CRAN release of semmcci
with:
install.packages("semmcci")
You can install the development version of semmcci
from
GitHub with:
if (!require("remotes")) install.packages("remotes")
remotes::install_github("jeksterslab/semmcci")
The Monte Carlo Method
In the Monte Carlo method, a sampling distribution of parameter estimates is generated from the multivariate normal distribution using the parameter estimates and the corresponding sampling variance-covariance matrix .
Confidence intervals for defined parameters are generated by obtaining percentiles corresponding to from the generated sampling distribution, where is the significance level.
semmcci
Monte Carlo confidence intervals for free and defined parameters
Monte Carlo confidence intervals for free and defined parameters in
models fitted in the structural equation modeling package
lavaan
can be generated using the semmcci
package. The package has three main functions, namely,
MC()
, MCMI()
, and MCStd()
. The
output of lavaan
is passed as the first argument to the
MC()
function or the MCMI()
function to
generate Monte Carlo confidence intervals. Monte Carlo confidence
intervals for the standardized estimates can also be generated by
passing the output of the MC()
function or the
MCMI()
function to the MCStd()
function. A
description of the package and code examples are presented in Pesigan
and Cheung (2023: https://doi.org/10.3758/s13428-023-02114-4).