View source: R/cal_m4measures.R
cal_m4measures | R Documentation |
Calculate MASE and sMAPE for an individual time series
cal_m4measures(training, test, forecast)
training |
training period of a time series |
test |
test peiod of a time series |
forecast |
forecast obtained from a fitted to the training period |
returns a single value: mean on MASE and sMAPE
Thiyanga Talagala
require(Mcomp) require(magrittr) ts <- Mcomp::M3[[1]]$x fcast_arima <- auto.arima(ts) %>% forecast(h=6) cal_m4measures(M3[[1]]$x, M3[[1]]$xx, fcast_arima$mean)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.