This function conducts expanding window forecasting.
forecast_expand(object, n_ahead, y_test, num_thread = 1, ...)# S3 method for olsmod
forecast_expand(object, n_ahead, y_test, num_thread = 1, ...)
# S3 method for normaliw
forecast_expand(object, n_ahead, y_test, num_thread = 1, use_fit = TRUE, ...)
# S3 method for ldltmod
forecast_expand(
object,
n_ahead,
y_test,
num_thread = 1,
level = 0.05,
stable = FALSE,
sparse = FALSE,
med = FALSE,
lpl = FALSE,
use_fit = TRUE,
verbose = FALSE,
...
)
# S3 method for svmod
forecast_expand(
object,
n_ahead,
y_test,
num_thread = 1,
level = 0.05,
use_sv = TRUE,
stable = FALSE,
sparse = FALSE,
med = FALSE,
lpl = FALSE,
use_fit = TRUE,
verbose = FALSE,
...
)
predbvhar_expand
Model object
Step to forecast in rolling window scheme
Test data to be compared. Use divide_ts() if you don't have separate evaluation dataset.
Additional arguments.
Specify alpha of confidence interval level 100(1 - alpha) percentage. By default, .05.
If
TRUE, use median of forecast draws instead of mean (default).
Print the progress bar in the console. By default, FALSE.
Use SV term
Expanding windows forecasting fixes the starting period.
It moves the window ahead and forecast h-ahead in y_test set.
Hyndman, R. J., & Athanasopoulos, G. (2021). Forecasting: Principles and practice (3rd ed.). OTEXTS. https://otexts.com/fpp3/