Learn R Programming

EFAtools (version 1.1.0)

print.efa_schmid_leiman: Print and format an efa_schmid_leiman object

Description

print() shows a summarised output of the efa_schmid_leiman() function: a model header (when the settings are available), the Schmid-Leiman loading matrix, and the variances accounted for. format() assembles the same report and returns it as a character vector; print() is cat(format(x), sep = "\n"). The lines follow the active console theme, so they are plain when colours are disabled (for example when captured into a file or stripped with cli::ansi_strip()).

Usage

# S3 method for efa_schmid_leiman
print(x, ...)

# S3 method for efa_schmid_leiman format(x, ...)

Value

print() returns its argument x invisibly. format() returns a character vector with the report lines.

Arguments

x

An object of class efa_schmid_leiman (output from efa_schmid_leiman()).

...

Not used; for consistency with the generic.

Examples

Run this code
EFA_mod <- efa_fit(test_models$baseline$cormat, N = 500, n_factors = 3,
                   estimator = "PAF", rotation = "promax")
sl_mod <- efa_schmid_leiman(EFA_mod, estimator = "PAF")
sl_mod

# format() returns the same lines as a character vector:
writeLines(format(sl_mod))

Run the code above in your browser using DataLab