powered by
Function that allows to calculate different types of errors for point predictions:
MAE - Mean Absolute Error,
MAD - Mean Absolute Deviation,
MSE - Mean Squared Error,
RMSE - Root Mean Squared Error,
MAPE - Mean Absolute Percentage Error,
sMAPE - symmetric Mean Absolute Percentage Error,
MASE - Mean Absolute Scaled Error (Hyndman & Koehler, 2006)
accmeasure( y_pred, y_true, which = c("RMSE", "MSE", "MAPE", "sMAPE", "MAE", "MAD", "MASE") )
The value of the chosen error is returned.
fitted values.
observed values.
one of c("RMSE", "MAPE", "sMAPE", "MAE", "MAD", "MASE")
Jorge Cabral, jorgecabral@ua.pt
Hyndman, R. J., & Koehler, A. B. (2006) Another look at measures of forecast accuracy. International Journal of Forecasting, 22(4), 679–688. tools:::Rd_expr_doi("10.1016/j.ijforecast.2006.03.001")
# \donttest{ res_gce_package <- lmgce(y ~ ., data = dataGCE, boot.B = 50, seed = 230676) # } accmeasure(fitted(res_gce_package), dataGCE$y, which = "MSE")
Run the code above in your browser using DataLab