"residuals"(object, type = c("recursive", "pearson", "response", "state", "deviance"), ...)
"recursive"
: One-step-ahead prediction residuals
$v[t,i]=y[t,i]-Z[t,i]a[t,i]$. For non-Gaussian case recursive
residuals are computed as $y[t]-Z[t]a[t]$, i.e.
non-sequentially. Computing recursive residuals for large non-Gaussian
models can be time consuming as filtering is needed.
"pearson"
: $$(y_{t,i}-\theta_{t,i})/\sqrt{V(\mu_{t,i})},
\quad i=1,\ldots,p,t=1,\ldots,n,$$ where $V(\mu[t,i])$ is the
variance function of the series $i$
"response"
: Data minus fitted values, $y-E(y)$.
"state"
: Residuals based on the smoothed disturbance terms
$\eta$ are defined as $$\hat \eta_t, \quad t=1,\ldots,n.$$
Only defined for fully Gaussian models.
"deviance"
: Deviance residuals. Deprecated. This option was
meant to be used only for the GLM comparisons, as their generalization to
other models is lacking, but these will be completely removed in future in
order to avoid misleading results in non-GLM settings.