timeVariable: Extract the time variable

timeVariableR Documentation

Extract the time variable

Description

Extracts the time variable (i.e., column name) from the given object.

Usage

## S4 method for signature 'lcMethod'
timeVariable(object, ...)

## S4 method for signature 'lcModel'
timeVariable(object)

Arguments

object

The object to extract the variable from.

...

Additional arguments.

Value

The time variable name, as character.

See Also

Other lcModel variables: idVariable(), responseVariable()

Examples

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

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