predict.esemifar {esemifar} | R Documentation |
ESEMIFAR Prediction Method
Description
Point and interval forecasts (under the normality assumption or via a bootstrap) for fitted ESEMIFAR models.
Usage
## S3 method for class 'esemifar'
predict(
object,
n.ahead = 5,
alpha = c(0.95, 0.99),
method = c("norm", "boot"),
bootMethod = c("simple", "advanced"),
npaths = 5000,
quant.type = 8,
boot_progress = TRUE,
expo = FALSE,
trend_extrap = c("linear", "constant"),
future = TRUE,
num_cores = future::availableCores() - 1,
...
)
Arguments
object |
|
n.ahead |
a single numeric value that represents the forecasting horizon. |
alpha |
a numeric vector with confidence levels for the forecasting
intervals; the default |
method |
whether to obtain the forecasting intervals under the
normality assumption ( |
bootMethod |
only for |
npaths |
only for |
quant.type |
only for |
boot_progress |
only for |
expo |
whether to exponentiate all results at the end. |
trend_extrap |
how to extrapolate the estimated trend into the future:
linearly ( |
future |
only for |
num_cores |
only for |
... |
no purpose; for compatibility only. |
Details
Produce point and interval forecasts based on ESEMIFAR models. Throughout, the infinite-order AR-representation of the parametric FARIMA part is considered to produce point forecasts and future paths of the series. The trend is usually extrapolated linearly (or constantly as an alternative).
Value
The function returns a list of class "esemifar"
with elements
nonpar_model
and par_model
.
A list with various elements is returned.
- obs
the observed series.
- mean
the point forecasts.
- lower
the lower bounds of the forecasting intervals.
- upper
the upper bounds of the forecasting intervals.
- model
the fitted ESEMIFAR model object.
- level
the confidence levels for the forecasting intervals.
Author(s)
Dominik Schulz (Scientific Employee) (Department of Economics, Paderborn University),
Author
Examples
lgdp <- log(esemifar::gdpG7$gdp)
est <- tsmoothlm(lgdp, pmax = 1, qmax = 1)
# Under normality
fc <- predict(est, n.ahead = 10, method = "norm", expo = TRUE)
fc$mean
fc$lower
fc$upper