prediction_info {vctsfr}R Documentation

Create an object with a prediction about the future values of a time series

Description

The object created contains a forecast and, optionally, prediction intervals for the forecast.

Usage

prediction_info(name, forecast, ...)

Arguments

name

a character indicating the name of the method used to forecast.

forecast

a time series of class ts or a vector. It is a prediction for the future values of a time series.

...

prediction intervals for the forecast. These prediction intervals must have been built with the pi_info() function.

Value

an object of class pred_info. A list with the information supplied to the function.

See Also

pi_info() for how to create prediction intervals.

Examples

if (require("forecast")) {
  time_series <- ts(rnorm(40))
  f <- meanf(time_series, level = 95)
  info <- prediction_info("mean", f$mean, pi_info(95, f$lower, f$upper))
}

[Package vctsfr version 0.1.1 Index]