Obtain point and interval forecasts based on fitted Seasonal Semi-ARMA models.
# S4 method for s_semiarma
predict(
object,
n.ahead = 1,
intervals = TRUE,
alpha = c(0.95, 0.99),
method = c("norm", "boot"),
bootMethod = c("simple", "advanced"),
npaths = 5000,
quant.type = 8,
expo = FALSE,
...
)
A list with the following elements is returned.
pred
the obtained point forecasts.
interv
the obtained forecasting intervals.
obs
the observation series.
ts_name
the name of the observation series object.
an object of class "s_semiarma"
.
a numeric vector of length one that represents the forecasting horizon; assume that object
is based on
observations at time points \(t=1,2,\dots,n\); forecasts are then obtained for time
points \(t=n+1,n+2,\dots,n+\code{n.ahead}\); the default is n.ahead = 1
.
a logical vector of length one that indicates whether or not
forecasting intervals should be obtained; the default is intervals = TRUE
.
a numeric vector of variable length that indicates the confidence levels
at which to obtain forecasting intervals; the default is alpha = c(0.95, 0.99)
,
i.e. confidence levels of 95 and 99 percent.
a character vector that indicates the method used to obtain forecasting
intervals; available are theoretical intervals based on the assumption of normal
innovations ("norm"
) and intervals through a bootstrap ("boot"
);
the default is method = "norm"
.
a character vector that allows the user to select a bootstrap
procedure for the forecasting intervals when method = "boot"
is selected;
the default bootMethod = "simple"
simulates future observations by resampling
the obtained residuals; the second approach bootMethod = "advanced"
also
considers the variation in the ARMA coefficient estimates by simulating and
reestimating complete ARMA paths upon which forecasts are obtained
(see also the B-ARMARoots algorithm in Lu and Wang, 2020); the second approach
is often time-consuming.
the number of paths to simulate, if the forecasting intervals are obtained via a bootstrap.
the method to obtain sample quantiles from the simulated
forecasting errors; see also the argument type
of the function
quantile
.
a logical vector of length one; indicates whether the forecasting
results should be exponentiated at the end; the default is expo = FALSE
.
only for comparability with the standard predict
method.
Dominik Schulz (Research Assistant) (Department of Economics, Paderborn
University),
Author and Package Creator
Assume a Seasonal Semi-ARMA model was fitted using s_semiarma
.
Pass the resulting object to this method, in order to obtain point and
interval forecasts.
# \donttest{
xt <- log(EXPENDITURES)
est <- s_semiarma(xt)
predict(est, n.ahead = 10)
# }
Run the code above in your browser using DataLab