lavNames: lavaan Names

Description Usage Arguments Details See Also Examples

View source: R/lav_partable_vnames.R

Description

Extract variables names from a fitted lavaan object.

Usage

1
lavNames(object, type = "ov", ...)

Arguments

object

An object of class lavaan.

type

Character. The type of variables whose names should be extracted. See details for a complete list.

...

Additional selection variables. For example "group = 2L" (in a multiple-group analysis) only considers the variables included in the model for the second group.

Details

The order of the variable names, as returned by lavNames determines the order in which the variables are listed in the parameter table, and therefore also in the summary output.

The following variable types are available:

See Also

lavaanify, parTable

Examples

1
2
3
4
5
6
HS.model <- ' visual  =~ x1 + x2 + x3
              textual =~ x4 + x5 + x6
              speed   =~ x7 + x8 + x9 '

fit <- cfa(HS.model, data=HolzingerSwineford1939)
lavNames(fit, "ov")

yrosseel/lavaan documentation built on Dec. 11, 2018, 3:42 a.m.