formula.lcModel: Extract the formula of a lcModel

View source: R/model.R

formula.lcModelR Documentation

Extract the formula of a lcModel

Description

Get the formula associated with the fitted lcModel object. This is determined by the formula argument of the lcMethod specification that was used to fit the model.

Usage

## S3 method for class 'lcModel'
formula(x, what = "mu", ...)

Arguments

x

The lcModel object.

what

The distributional parameter.

...

Additional arguments.

Value

Returns the associated formula, or response ~ 0 if not specified.

See Also

stats::formula

Examples

data(latrendData)
method <- lcMethodLMKM(Y ~ Time, id = "Id", time = "Time")
model <- latrend(method, data = latrendData)
formula(model) # Y ~ Time

latrend documentation built on March 31, 2023, 5:45 p.m.