sediWeighted | R Documentation |
This function calculates the symmetric extremal dependence index (SEDI) using a threshold applied to continuous data to demarcate "presence" from "contrast".
sediWeighted( pres, contrast, presWeight = rep(1, length(pres)), contrastWeight = rep(1, length(contrast)), thresholds = seq(0, 1, by = 0.01), delta = 0.001, na.rm = FALSE, bg = NULL, bgWeight = NULL, ... )
pres |
Numeric vector. Predicted values at presence sites. |
contrast |
Numeric vector. Predicted values at absence/background sites. |
presWeight |
Numeric vector same length as |
contrastWeight |
Numeric vector same length as |
thresholds |
Numeric vector, Values at which to threshold predictions for calculation of SEDI. |
delta |
Positive numeric >0 in the range [0, 1] and usually very small. This value is used only if calculating the SEDI threshold when any true positive rate or false negative rate is 0 or the false negative rate is 1. Since SEDI uses log(x) and log(1 - x), values of 0 and 1 will produce |
na.rm |
Logical. If |
bg |
Same as |
bgWeight |
Same as |
... |
Other arguments (unused). |
Numeric value.
Wunderlich, R.F., Lin, Y-P., Anthony, J., and Petway, J.R. 2019. Two alternative evaluation metrics to replace the true skill statistic in the assessment of species distribution models. Nature Conservation 35:97-116.
cor
, fpb
, aucWeighted
, link[enmSdm]{contBoyce}
, link[enmSdm]{contBoyce2x}
, link[enmSdm]{thresholdWeighted}
, link[enmSdm]{thresholdStats}
set.seed(123) pres <- sqrt(runif(100)) contrast <- runif(10000) hist(contrast, col='gray', xlim=c(0, 1), breaks=20) hist(pres, col='green', breaks=20, add=TRUE) max(sediWeighted(pres, contrast), na.rm=TRUE) # SEDI is fairly insensitive to weighting (as per Wunderlich et al. 2019) presWeight <- c(rep(1, 50), rep(1000, 50)) max(sediWeighted(pres, contrast, presWeight=presWeight), na.rm=TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.