sigma() returns the fitted scale-like parameter from a drmTMB model. For
univariate Gaussian location-scale models this is the fitted residual
sigma_i vector on the response scale. For Student-t models this is the
Student-t scale parameter; when nu > 2, the residual standard deviation is
sigma * sqrt(nu / (nu - 2)). For skew-normal models this is the response
standard deviation under the public moment parameterization, not the native
Azzalini scale omega. For lognormal models this is the fitted
standard deviation of log(y). For Gamma models this is the fitted
coefficient of variation. For Tweedie models this is the public scale
parameter where internal dispersion is phi = sigma^2. For beta,
zero-one beta, and beta-binomial models this is the public scale parameter
where internal precision is phi = 1 / sigma^2.
Cumulative-logit ordinal, binomial, Poisson, and zero-inflated Poisson models have no
fitted residual scale parameter and return a fixed unit dispersion vector
for consistency with base-R sigma() conventions. For
negative-binomial 2, zero-truncated negative-binomial 2, hurdle
negative-binomial 2, and zero-inflated negative-binomial 2 models this is
the fitted overdispersion scale in the untruncated NB2 component
Var(y | component) = mu + sigma^2 * mu^2. For bivariate Gaussian models
it returns a roundable list with fitted sigma1 and sigma2 vectors.
Usage
# S3 method for class 'drmTMB'
sigma(object, ...)Value
A numeric vector for univariate models, or a named, roundable list of numeric vectors for bivariate Gaussian models.