Learn R Programming

sirad (version 2.3-1)

modeval: Model performance statistics.

Description

Function estimates several statistics comparing modelled and reference (measured) values.

Usage

modeval(calculated,measured, stat=c("N","pearson","MBE","RMBE","MAE","RMAE","RMSE","RRMSE","R2","slope", "intercept","EF","SD","CRM","MPE","AC","ACu","ACs"),minlength=4)

Arguments

calculated
Vector of length n of the calculated (modelled) values.
measured
Vector of length n of the reference (measured) values.
stat
Statistics which are going to be calculated. By default all possible.
minlength
Minimum number of non-NA data pairs. If below this value, the NA's are produced.

Value

List of 13 statistics:
N
number of observations
person
Pearson's Correlation Coefficient
MBE
Mean (Bias) Error
RMBE
Relative Mean (Bias) Error
MAE
Mean Absolute Error
RMAE
Relative Mean Absolute Error
RMSE
Root Mean Square Error
RRMSE
Relative Root Mean Square Error
R2
Coefficient of determination from linear model
slope
Slope from linear model
intercept
Intercept from linear model
EF
Modelling Efficiency
SD
Standard deviation of differences
CRM
Coefficient of Residual Mass
MPE
Mean Percentage Error
AC
Agreement Coefficient
ACu
Unsystematic Agreement Coefficient
ACs
Systematic Agreement Coefficient

Details

The two input vectors can include NA's. Only non-NA calculated-mesured pairs are used. See 'na.omit' for details.

References

Bellocchi, G., Acutis, M., Fila, G., Donatelli, M., 2002. An indicator of solar radiation model performance based on a fuzzy expert system. Agronomy Journal 94, 1222-1233. Ji, L., Gallo, K., 2006. An Agreement Coefficient for image comparison. Photogrammetric Engineering & Remote Sensing 72(7), 823-833.

Examples

Run this code

data(Metdata)
B <- 0.11
tmax <- Metdata$meteo$TEMP_MAX
tmin <- Metdata$meteo$TEMP_MIN
days <- Metdata$meteo$DAY
lat <- Metdata$LATITUDE
solrad_measured <- Metdata$meteo$RAD_MEA
solrad_BC <- bc(days, lat, extraT=NULL, BCb=B, tmax, tmin, BCc=2, tal=0.76) 

modeval(solrad_BC,solrad_measured)
modeval(solrad_BC,solrad_measured,stat="EF")

Run the code above in your browser using DataLab