residuals: Model Residuals

residuals.arima.estimateR Documentation

Model Residuals

Description

Extract the residual values from an estimated model.

Usage

## S3 method for class 'arima.estimate'
residuals(object, raw = FALSE, ...)

## S3 method for class 'bsts.estimate'
residuals(
  object,
  distribution = FALSE,
  invdiff = TRUE,
  standardize = FALSE,
  raw = FALSE,
  type = c("filtered", "smoothed"),
  ...
)

Arguments

object

an object of class “tsissm.estimate”.

raw

raw residuals are the model based values in transformed space (when either Box Cox or Logistic have been used as transformations).

...

not currently used.

distribution

whether to return the full distribution for the bsts model.

invdiff

if a model in differences was estimated, whether to inverse the differencing when calculating the residual values.

standardize

whether to scale the errors by the model standard deviation.

type

for the bsts model, the filtered are the one step ahead forecast errors, whilst the smoothed represent those values using the whole information set.

Value

For the distribution choice, an object of class “tsmodel.distribution”, else an xts vector.


tsmodels/tsforeign documentation built on June 22, 2022, 2:09 p.m.