Skip to contents

Mean absolute difference between the observations (0/1) and the predicted suitability. Lower is better.

Usage

mae_score(obs, pred)

Arguments

obs

Numeric vector of observations (1 = presence, 0 = absence).

pred

Numeric vector of predicted suitability.

Details

Limits. With many background points it rewards predicting low values everywhere (see mae_balanced()); with background points it does not measure the error of occurrence probabilities.

References

Konowalik, K., Nosol, A. (2021) Evaluation metrics and validation of presence-only species distribution models based on distributional maps with varying coverage. Scientific Reports 11, 1482. doi:10.1038/s41598-020-80062-1

Examples

mae_score(c(1, 1, 0, 0), c(0.9, 0.6, 0.7, 0.1))
#> [1] 0.325