computeResiduals: Compute VAR Model Residuals

View source: R/main_function.R

computeResidualsR Documentation

Compute VAR Model Residuals

Description

Computes the residuals from a VAR model by subtracting the fitted values (obtained from the estimated coefficient matrices) from the original time series data.

Usage

computeResiduals(data, A)

Arguments

data

A numeric matrix of the original time series (observations in rows).

A

List. A list of VAR coefficient matrices (one for each lag).

Value

A numeric matrix of residuals.


VARcpDetectOnline documentation built on April 12, 2025, 1:44 a.m.