GOF_rmse {HyMETT} | R Documentation |
Calculate root-mean-square error with options to normalize
Description
Calculate root-mean-square error (RMSE) between modeled (simulated) and observed values. Error is defined as modeled minus observed.
Usage
GOF_rmse(
mod,
obs,
normalize = c("none", "mean", "range", "stdev", "iqr", "iqr-1", "iqr-2", "iqr-3",
"iqr-4", "iqr-5", "iqr-6", "iqr-7", "iqr-8", "iqr-9", NULL),
na.rm = TRUE
)
Arguments
mod |
'numeric' vector. Modeled or simulated values. Must be same length as |
obs |
'numeric' vector. Observed or comparison values. Must be same length as |
normalize |
'character' value. Option to normalize the root-mean-square error (NRMSE) by
several normalizing options. Default is |
na.rm |
'boolean' |
Value
'numeric' value of computed root-mean-square error (RMSE) or normalized root-mean-square error (NRMSE)
Examples
# RMSE
GOF_rmse(mod = example_mod$streamflow_cfs, obs = example_obs$streamflow_cfs)
# NRMSE
GOF_rmse(
mod = example_mod$streamflow_cfs, obs = example_obs$streamflow_cfs, normalize = 'stdev'
)