fitforecast(
  y,
  h = NULL,
  pct_train = 0.9,
  pct_calibration = 0.5,
  method = c("thetaf", "arima", "ets", "te", "tbats", "tslm", "dynrmf", "ridge2f",
    "naive", "snaive"),
  level = 95,
  B = 1000L,
  seed = 17223L,
  graph = TRUE,
  conformalize = FALSE,
  type_calibration = c("splitconformal", "cv1", "loocv"),
  gap = 3L,
  agg = c("mean", "median"),
  vol = c("constant", "garch"),
  type_sim = c("kde", "surrogate", "bootstrap"),
  ...
)

Arguments

y

A univariate time series of class ts

h

Forecasting horizon (default is NULL, in that case, pct_train and pct_calibration are used)

pct_train

Percentage of data in the training set, when h is NULL

pct_calibration

Percentage of data in the calibration set for conformal prediction

method

For now "thetaf" (default), "arima", "ets", "tbats", "tslm", "dynrmf" (from ahead), "ridge2f" (from ahead), "naive", "snaive"

level

Confidence level for prediction intervals in

BNumber of bootstrap replications or number of simulations (yes, 'B' is unfortunate)

seedReproducibility seed

graphPlot or not?

conformalizeCalibrate or not?

type_calibration"splitconformal" (default conformal method), "cv1" (do not use), "loocv" (do not use)

gaplength of training set for loocv conformal (do not use)

agg"mean" or "median" (aggregation method) for

vol"constant" or "garch" (type of volatility modeling for calibrated residuals)

type_sim"kde", "surrogate", "bootstrap" (type of simulation for calibrated residuals)

...additional parameters

an object of class 'forecast' with additional information

Fit and forecast for benchmarking purposes

par(mfrow=c(2, 2)) obj1 <- ahead::fitforecast(AirPassengers) obj2 <- ahead::fitforecast(AirPassengers, conformalize = TRUE) plot(AirPassengers) plot(obj1) obj2$plot() obj2$plot("simulations")