forecast.ESN: Forecast an Echo State Network
Description
Forecast an Echo State Network (ESN) from a trained model via
recursive forecasting. Forecast intervals are generated by simulating
future sample path based on a moving block bootstrap of the residuals and
estimating the quantiles from the simulations. The function is a wrapper
for forecast_esn() and intended to be used in combination with
fabletools::model().
Usage
# S3 method for ESN
forecast(
object,
new_data,
normal = TRUE,
n_sim = 200,
specials = NULL,
xreg = NULL,
...
)
Value
An object of class fbl_ts ("fable").
Arguments
- object
An object of class mdl_df, containing an ESN model.
- new_data
Forecast horizon (n-step ahead forecast).
- normal
Logical value. If TRUE, dist_normal() is used, otherwise dist_sample().
- n_sim
Integer value. The number of future sample path generated during simulation.
- specials
Currently not in use.
- xreg
A tsibble containing exogenous variables.
- ...
Currently not in use.
Examples
Run this codelibrary(tsibble)
library(fable)
AirPassengers %>%
as_tsibble() %>%
model("ESN" = ESN(value)) %>%
forecast(h = 18)
Run the code above in your browser using DataLab