iForecast_var: Produce multistep forecasts from machine learning VAR

iForecast.varR Documentation

Produce multistep forecasts from machine learning VAR

Description

It generates multistep forecasts of machine learning VAR.

Usage


iForecast.var(object, n.ahead)

Arguments

object

The object generated by tts.var.

n.ahead

The number of out-of-sample forecasting periods. If n.ahead=1, it is one-step forecast; if n.ahead>1, it computes multistep forecasts by recursive method.

Details

This function generates multistep forecasts of machine learning VAR.

Author(s)

Ho Tsung-wu <tsungwu@ntnu.edu.tw>, College of Management, National Taiwan Normal University.

Examples

data(macrodata)
y=timeSeries::as.timeSeries(macrodata[,-1])
VLD=window(y,start="2019-01-01",end=end(y))
#OUT1=tts.var(data=y,
#             p=3,
#             method="enet",
#             train.end="2018-12-01",
#             type=c("none","trend","season","both")[1])

#fcst_ml=iForecast.var(OUT1, n.ahead=nrow(VLD))

iForecast documentation built on June 28, 2025, 5:06 p.m.