R/modeltime_multiforecast.R
modeltime_multiforecast.Rdallows forecasting on multiple time series from multiple fitted models.
modeltime_multiforecast(models_table, .h = NULL, .prop = NULL)
| models_table | 'table_time' tibble generated with the |
|---|---|
| .h | prediction horizon of the |
| .prop | time series split partition ratio. If "h" is specified, this function predicts on the testing partition. |
'models_table' tibble with a new column called 'nested_forecast' where the predictions are stored.
this function takes the 'table_time' object generated with the modeltime_multifit() function,
the modeltime_forecast() from the package 'modeltime' is applied to each model for each series.
# Data data_serie <- sknifedatar::table_time # Forecast sknifedatar::modeltime_multiforecast(data_serie$table_time, .prop=0.8)#> # A tibble: 2 x 7 #> sector nested_column m_ets m_nnetar nested_model calibration nested_forecast #> <chr> <list> <lis> <list> <list> <list> <list> #> 1 Comerc… <tibble [49 ×… <fit… <fit[+]> <model_time… <model_tim… <tibble [69 × … #> 2 Ensena… <tibble [49 ×… <fit… <fit[+]> <model_time… <model_tim… <tibble [69 × …