Closed mdancho84 closed 3 years ago
The deep_state()
function implements the GluonTS DeepStateEstimator()
.
library(modeltime.gluonts)
library(tidymodels)
library(tidyverse)
library(timetk)
splits <- walmart_sales_weekly %>%
time_series_split(
assess = 26,
cumulative = TRUE
)
model_fit_deepstate <- deep_state(
id = "id",
freq = "W",
prediction_length = 26,
lookback_length = 52*2,
add_trend = FALSE,
epochs = 2,
scale = TRUE
) %>%
set_engine("gluonts_deepstate") %>%
fit(Weekly_Sales ~ Date + id, training(splits))
Implement the DeepState algorithm.