noisemaker | R Documentation |
This tool lets the user generate a population correlation matrix with model error using one of three methods: (1) the Tucker, Koopman, and Linn (TKL; 1969) method, (2) the Cudeck and Browne (CB; 1992) method, or (3) the Wu and Browne (WB; 2015) method. If the CB or WB methods are used, the user can specify the desired RMSEA value. If the TKL method is used, an optimization procedure finds a solution that produces RMSEA and/or CFI values that are close to the user-specified values.
noisemaker(
mod,
method = c("TKL", "CB", "WB"),
target_rmsea = 0.05,
target_cfi = NULL,
tkl_ctrl = list(),
wb_mod = NULL
)
mod |
A |
method |
(character) Model error method to use ("TKL", "CB", or "WB"). |
target_rmsea |
(scalar) Target RMSEA value. |
target_cfi |
(scalar) Target CFI value. |
tkl_ctrl |
(list) A control list containing the following TKL-specific
arguments. See the |
wb_mod |
('lm' object) An optional |
A list containing \Sigma
, RMSEA and CFI values, and the TKL
parameters (if applicable).
mod <- fungible::simFA(Seed = 42)
set.seed(42)
# Simulate a population correlation matrix using the TKL method with target
# RMSEA and CFI values specified.
noisemaker(mod, method = "TKL",
target_rmsea = 0.05,
target_cfi = 0.95,
tkl_ctrl = list(optim_type = "optim"))
# Simulate a population correlation matrix using the CB method with target
# RMSEA value specified.
noisemaker(mod, method = "CB",
target_rmsea = 0.05)
# Simulation a population correlation matrix using the WB method with target
# RMSEA value specified.
noisemaker(mod,
method = "WB",
target_rmsea = 0.05)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.