BaşlayınÜcretsiz Başlayın

Build time series forecast for new region

So you have built models forecasting sales for the metropolitan region in your lessons and the mountain region in the videos. Let's build a middle-out forecast for the southeast coastal region and then we will have completed the whole state's hierarchy! In your workspace you have SEC_total for sales and dates_valid and SEC_t_v for validation.

Bu egzersiz

Forecasting Product Demand in R

kursunun bir parçasıdır
Kursu Görüntüle

Egzersiz talimatları

  • Build a time series model for the southeast coastal regional sales (SEC_total).
  • Forecast out 22 values into 2017.
  • Make this forecast an xts object using the date index dates_valid.
  • Calculate the MAPE.

Uygulamalı interaktif egzersiz

Bu örnek kodu tamamlayarak bu egzersizi bitirin.

# Build a time series model for the region using auto.arima
SEC_t_model_arima <- ___(___)

# Forecast the time series model
for_SEC_t <- ___(___, h = ___)

# Make into an xts object from the forecast you just made
for_SEC_t_xts <- ___(___$mean, order.by = ___)

# Calculate the MAPE
MAPE <- mape(___, SEC_t_v)
print(MAPE)
Kodu Düzenle ve Çalıştır