Learn R Programming

fungible (version 2.4.4)

cfi: Calculate CFI for two correlation matrices

Description

Given two correlation matrices of the same dimension, calculate the CFI value value using the independence model as the null model.

Usage

cfi(Sigma, Omega)

Arguments

Sigma

(matrix) Population correlation or covariance matrix (with model error).

Omega

(matrix) Model-implied population correlation or covariance matrix.

Examples

Run this code
library(fungible)

mod <- fungible::simFA(Model = list(NFac = 3),
                       Seed = 42)
set.seed(42)
Omega <- mod$Rpop
Sigma <- noisemaker(
  mod = mod,
  method = "CB",
  target_rmsea = 0.05
)$Sigma
cfi(Sigma, Omega)

Run the code above in your browser using DataLab