rolling_horizon: Rolling horizon

Description Usage Arguments Value

View source: R/rol_hor_functions.R

Description

Test time series models with the rolling horizon method.

Usage

1
2
rolling_horizon(series, FUN, FUN_PRED, start_eval, eval_periods = 4,
  h = 14, regressors = NULL)

Arguments

series

Time series of the target variable.

FUN

Training function, returns a model-object.

FUN_PRED

Prediction function, returns a prediction.

start_eval

Vector in the shape c(year, period) that form the last point of the first rolling horizon.

eval_periods

Number of rolling horizons.

h

Horizon length.

Value

A list of the metrics, data for plotting and the trained models.


alexanderharms/timsR documentation built on May 21, 2020, 12:57 p.m.