Learn R Programming

EFAtools (version 0.8.0)

print.KMO: Print and format a KMO object

Description

print() shows the Kaiser-Meyer-Olkin (KMO) criterion computed by KMO(): a titled section with a verdict on the overall KMO value (and what it implies for the suitability of the data for factor analysis), the overall value, and the per-variable KMO values. 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 KMO
print(x, ...)

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

Value

print() returns its argument x invisibly. format() returns a character vector with the report lines (styled to the active console theme; plain when colours are disabled).

Arguments

x

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

...

Not used; for consistency with the generic.

Examples

Run this code
KMO_base <- KMO(test_models$baseline$cormat)
KMO_base

# format() returns the same lines as plain text:
writeLines(format(KMO_base))

Run the code above in your browser using DataLab