Skip to contents

Response residuals are Y - fitted(object) in each period. Pearson residuals scale them by the standard deviation the family assigns to a response with that fitted value, as in residuals.ame: the residual variance for the normal family, \(\mu (1 - \mu)\) for binary, \(\mu + \mu^2 (e^{\sigma^2_e} - 1)\) for Poisson (the fitted mean \(\mu\) carries the exposure of the period), and the variance of the category distribution at the posterior-mean linear predictor for ordinal fits. A cell whose variance is zero is NA.

Usage

# S3 method for class 'lame'
residuals(object, type = c("response", "pearson"), ...)

Arguments

object

Fitted LAME model

type

Type of residuals ("response" or "pearson")

...

Additional arguments

Value

List of residual matrices (one per time point)