accmeasure {GCEstim} | R Documentation |
Accuracy measures
Description
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)
Usage
accmeasure(
y_pred,
y_true,
which = c("RMSE", "MSE", "MAPE", "sMAPE", "MAE", "MAD", "MASE")
)
Arguments
y_pred |
fitted values. |
y_true |
observed values. |
which |
one of c("RMSE", "MAPE", "sMAPE", "MAE", "MAD", "MASE") |
Value
The value of the chosen error is returned.
Author(s)
Jorge Cabral, jorgecabral@ua.pt
References
Hyndman, R. J., & Koehler, A. B. (2006)
Another look at measures of forecast accuracy.
International Journal of Forecasting, 22(4), 679–688.
doi:10.1016/j.ijforecast.2006.03.001
Examples
res_gce_package <-
lmgce(y ~ .,
data = dataGCE,
boot.B = 50,
seed = 230676)
accmeasure(fitted(res_gce_package), dataGCE$y, which = "MSE")
[Package GCEstim version 0.1.0 Index]