print.lrtp {semlrtp}R Documentation

Print an 'lrtp'- Class Object

Description

Print the content of an lrtp-class object.

Usage

## S3 method for class 'lrtp'
print(
  x,
  digits = 3,
  lrtp_only = TRUE,
  wald_stats = FALSE,
  output = c("text", "data.frame", "table"),
  ...
)

Arguments

x

An lrtp-class object.

digits

Integer. The number of decimal places to print. Default is 3.

lrtp_only

Logical. If TRUE, the default, only parameters with LRT p-values will be printed.

wald_stats

Logical. If TRUE, the usual Wald statistics (e.g., z statistics, p-values, CIs) are printed. FALSE by default, assuming that users prefer using LRT statistics when using lrtp().

output

The format of the printout. If "text", then the style in the summary() of the lavaan-class object is used. If "data.frame" or "table", then the data frame format of lavaan::parameterEstimates() is used.

...

Optional arguments. Not used.

Details

The print method for the output of lrtp().

Additional diagnostic information will be printed if one or more likelihood tests encounter some errors or warnings.

Value

x is returned invisibly. Called for its side effect.

Author(s)

Shu Fai Cheung https://orcid.org/0000-0002-9871-9448

See Also

lrtp()

Examples


library(lavaan)
data(data_sem16)
mod <-
"
f1 =~ x1 + x2 + x3
f2 =~ x4 + x5 + x6
"
fit <- sem(mod, data_sem16)

out <- lrtp(fit)
out
print(out, lrtp_only = FALSE)


[Package semlrtp version 0.1.1 Index]