check_res: Visualization of the Residuals of a Time Series Model

View source: R/forecast_tools.R

check_resR Documentation

Visualization of the Residuals of a Time Series Model

Description

Provides a visualization of the residuals of a time series model. That includes a time series plot of the residuals, and the plots of the autocorrelation function (acf) and histogram of the residuals

Usage

check_res(ts.model, lag.max = 36)

Arguments

ts.model

A time series model (or forecasted) object, support any model from the forecast package with a residuals output

lag.max

The maximum number of lags to display in the residuals' autocorrelation function plot

Examples

library(forecast)
data(USgas)

# Create a model
fit <- auto.arima(USgas)

# Check the residuals of the model
check_res(fit)

TSstudio documentation built on Aug. 9, 2023, 9:06 a.m.