Skip to content

Instantly share code, notes, and snippets.

@jroberayalas
Created April 16, 2017 23:48
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jroberayalas/d13a5b290ebfbd8eb2c9c0243db5d64a to your computer and use it in GitHub Desktop.
Save jroberayalas/d13a5b290ebfbd8eb2c9c0243db5d64a to your computer and use it in GitHub Desktop.
# Retrain using train and validation set
retrain <- bind_rows(train, valid)
retrain$cap <- best_params$capacity
m <- prophet(retrain, growth = best_params$growth, holidays = holidays,
seasonality.prior.scale = best_params$seasonality_prior_scale,
changepoint.prior.scale = best_params$changepoint_prior_scale,
holidays.prior.scale = best_params$holidays_prior_scale)
future <- make_future_dataframe(m, periods = 184)
future$cap <- best_params$capacity
forecast <- predict(m, future)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment