Title: | Performance Metrics in Predictive Modeling |
---|---|
Description: | Performance metric provides different performance measures like mean squared error, root mean square error, mean absolute deviation, mean absolute percentage error etc. of a fitted model. These can provide a way for forecasters to quantitatively compare the performance of competing models. For method details see (i) Pankaj Das (2020) <http://krishi.icar.gov.in/jspui/handle/123456789/44138>. |
Authors: | Pankaj Das [aut, cre] |
Maintainer: | Pankaj Das <[email protected]> |
License: | MIT + file LICENSE |
Version: | 0.1.0 |
Built: | 2024-12-12 07:03:04 UTC |
Source: | CRAN |
Accuracy of Model
accuracy(actual, predicted)
accuracy(actual, predicted)
actual |
Actual value of the target variable |
predicted |
Predicted/forecasted value of the target variable |
Accuracy of the fitted model
actual <- c(100, 150, 200, 250, 300, 350, 400, 450, 500, 550) predicted <- c(95, 148, 210, 245, 290, 360, 395, 440, 510, 540) accuracy(actual, predicted)
actual <- c(100, 150, 200, 250, 300, 350, 400, 450, 500, 550) predicted <- c(95, 148, 210, 245, 290, 360, 395, 440, 510, 540) accuracy(actual, predicted)
Coefficient of Variation of Root Mean Squared Error
CVRMSE(actual, predicted)
CVRMSE(actual, predicted)
actual |
Actual value of the target variable |
predicted |
Predicted/forecasted value of the target variable |
CVRMSE of the fitted model
actual <- c(100, 150, 200, 250, 300, 350, 400, 450, 500, 550) predicted <- c(95, 148, 210, 245, 290, 360, 395, 440, 510, 540) CVRMSE(actual, predicted)
actual <- c(100, 150, 200, 250, 300, 350, 400, 450, 500, 550) predicted <- c(95, 148, 210, 245, 290, 360, 395, 440, 510, 540) CVRMSE(actual, predicted)
Mean Absolute Error
MAE(actual, predicted)
MAE(actual, predicted)
actual |
Actual value of the target variable |
predicted |
Predicted/forecasted value of the target variable |
MAE of the fitted model
actual <- c(100, 150, 200, 250, 300, 350, 400, 450, 500, 550) predicted <- c(95, 148, 210, 245, 290, 360, 395, 440, 510, 540) MAE(actual, predicted)
actual <- c(100, 150, 200, 250, 300, 350, 400, 450, 500, 550) predicted <- c(95, 148, 210, 245, 290, 360, 395, 440, 510, 540) MAE(actual, predicted)
Mean Absolute Percentage Error
MAPE(actual, predicted)
MAPE(actual, predicted)
actual |
Actual value of the target variable |
predicted |
Predicted value of the target variable |
MAPE of the fitted model
actual <- c(100, 150, 200, 250, 300, 350, 400, 450, 500, 550) predicted <- c(95, 148, 210, 245, 290, 360, 395, 440, 510, 540) MAPE(actual, predicted)
actual <- c(100, 150, 200, 250, 300, 350, 400, 450, 500, 550) predicted <- c(95, 148, 210, 245, 290, 360, 395, 440, 510, 540) MAPE(actual, predicted)
Maximum Error
ME(actual, predicted)
ME(actual, predicted)
actual |
Actual value of the target variable |
predicted |
Predicted value of the target variable |
ME of the fitted model
actual <- c(100, 150, 200, 250, 300, 350, 400, 450, 500, 550) predicted <- c(95, 148, 210, 245, 290, 360, 395, 440, 510, 540) ME(actual, predicted)
actual <- c(100, 150, 200, 250, 300, 350, 400, 450, 500, 550) predicted <- c(95, 148, 210, 245, 290, 360, 395, 440, 510, 540) ME(actual, predicted)
Normalised Root Mean Squared Error
NRMSE(actual, predicted)
NRMSE(actual, predicted)
actual |
Actual value of the target variable |
predicted |
Predicted value of the target variable |
NRMSE of the fitted model
actual <- c(100, 150, 200, 250, 300, 350, 400, 450, 500, 550) predicted <- c(95, 148, 210, 245, 290, 360, 395, 440, 510, 540) NRMSE(actual, predicted)
actual <- c(100, 150, 200, 250, 300, 350, 400, 450, 500, 550) predicted <- c(95, 148, 210, 245, 290, 360, 395, 440, 510, 540) NRMSE(actual, predicted)
Coefficient of Determination (R-Square)
R2(actual, predicted)
R2(actual, predicted)
actual |
Actual value of the target variable |
predicted |
Predicted value of the target variable |
Coefficient of Determination (R-Square) of the fitted model
actual <- c(100, 150, 200, 250, 300, 350, 400, 450, 500, 550) predicted <- c(95, 148, 210, 245, 290, 360, 395, 440, 510, 540) R2(actual, predicted)
actual <- c(100, 150, 200, 250, 300, 350, 400, 450, 500, 550) predicted <- c(95, 148, 210, 245, 290, 360, 395, 440, 510, 540) R2(actual, predicted)
Root Mean Squared Error
RMSE(actual, predicted)
RMSE(actual, predicted)
actual |
Actual value of the target variable |
predicted |
Predicted value of the target variable |
RMSE and MSE of the fitted model
actual <- c(100, 150, 200, 250, 300, 350, 400, 450, 500, 550) predicted <- c(95, 148, 210, 245, 290, 360, 395, 440, 510, 540) RMSE(actual, predicted)
actual <- c(100, 150, 200, 250, 300, 350, 400, 450, 500, 550) predicted <- c(95, 148, 210, 245, 290, 360, 395, 440, 510, 540) RMSE(actual, predicted)