Skip to contents

Summary table of model fit aggregated over k-folds

Usage

agg_model_fit(kfits, index = "all", digits = 2)

Arguments

kfits

an object returned from k_model_fit when by.folds = TRUE

index

character; one or more fit indices to summarize. Indices must be present in the kfits object. Default is "all" indices present in kfits. Chi-square value and degrees of freedom are always reported.

digits

integer; number of decimal places to display in the report

Value

data.frame of aggregated model fit statistics

Examples

data(example.kfa)
fits <- k_model_fit(example.kfa, by.fold = TRUE)
agg_model_fit(fits)
#>      model df.scaled mean.chisq.scaled range.chisq.scaled mean.cfi.scaled
#> 1 1-factor  51.31415          509.7963    489.32 - 530.27      0.08599637
#> 2 2-factor  58.37055          401.2840    401.28 - 401.28      0.28318479
#> 3 3-factor 109.54457          110.8768    103.04 - 118.71      0.99011777
#>   range.cfi.scaled mean.rmsea.scaled range.rmsea.scaled
#> 1      0.07 - 0.10        0.14126407        0.14 - 0.15
#> 2      0.28 - 0.28        0.11413192        0.11 - 0.11
#> 3      0.98 - 1.00        0.00730626        0.00 - 0.01