eta: Generate a vector of "ETA"

View source: R/eta.R

etaR Documentation

Generate a vector of "ETA"

Description

Generate a vector of "ETA" values. If x is a mrgsolve model, these will be extracted from values defined in ⁠$PARAM⁠. Otherwise, any numeric values passed to x and ... as vector(s) or list(s) will be coerced as a single vector. Alternatively, if x and ... are missing, generate a vector of ETA equal to val of length n.

Usage

eta(x, ..., n, val = 0)

Arguments

x

either a mrgsolve model object, or a numeric

...

additional numeric(s)

n, val

generate a sequence of val of length n

Value

a single named vector of numeric

Examples

# Extract ETA from the model
mod <- exmodel()
eta(mod)

# Coerce numeric values
eta(0.1, 0.2, c(0.3, 0.4), list(0.5, 0.6))
eta(rnorm(4))

# Generate a sequence from scratch
eta(n = 3)
eta(n = 3, val = 0.001)

mapbayr documentation built on July 26, 2023, 5:16 p.m.