plot.forecast_esn | R Documentation |
Plot point forecasts, actual and fitted values of a trained ESN model as line chart. Optionally, test data (out-of-sample) can be added to the plot.
## S3 method for class 'forecast_esn'
plot(x, test = NULL, fitted = TRUE, interval = TRUE, n_obs = NULL, ...)
x |
An object of class |
test |
Numeric vector. Test data, i.e., out-of-sample actual values. |
fitted |
Logical value. If |
interval |
Logical value. If |
n_obs |
Integer value. If |
... |
Currently not in use. |
Line chart of point forecast and actual values.
xdata <- as.numeric(AirPassengers)
xmodel <- train_esn(y = xdata)
xfcst <- forecast_esn(xmodel, n_ahead = 12)
plot(xfcst)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.