Perform out-of-sample prediction of a given ARIMA model and compute the summary statistics
backtest(m1, rt, orig, h = 1, xre = NULL, fixed = NULL,
inc.mean = TRUE, reest = 1, method = c("CSS-ML"))
An output of the arima command for scalar time series
The time series under consideration
The starting forecast origin. It should be less than the length of the underlying time series
The forecast horizon. For a given h, it computes 1-step to h-step ahead forecasts
A logical switch. It is true if mean vector is estimated.
A vector of the length of the number of coefficients of the ARIMA model. It is used in R for parameter constraint.
A matrix containing the exogeneous variables used in the ARIMA model
A control variable used to re-fit the model in prediction. The program will re-estimate the model for every new reest observations. The default is 1. That is, re-estimate the model with every new data point.
Estimation method in the ARIMA model
Forecast origin
forecast errors
forecasts
Root mean squared forecast errors
Mean absolute forecast errors
Return the reest value
Perform estimation-prediction-reestimation in the forecasting subsample, and to compuate the summary statistics
Tsay (2010). Analysis of Financial Time Series, 3rd. John Wiley. Hoboken, NJ.