Last chance! 50% off unlimited learning
Sale ends in
Estimates the Jaccard index for comparing two binary maps
jaccard(m1, m2)
Returns a data.frame with three values: 1) jaccard (Jaccard index),
2) percentage_m1 (the percentage of m1 that the
intersection
A binary raster A or an object of class setA returned by
the function model2sparse
.
A binary raster A or an object of class setA returned by
the function model2sparse
.
Luis Osorio-Olvera & Jorge Soberón
The Jaccard index is computed as follows
m1_path <- system.file("extdata/conejos/Lepus_othus_cont.tif",
package = "bamm")
m2_path <- system.file("extdata/conejos/Brachylagus_idahoensis_cont.tif",
package = "bamm")
m1 <- raster::raster(m1_path) > 0.01
m2 <- raster::raster(m2_path) >0.01
jcc <- bamm::jaccard(m1,m2)
print(jcc)
Run the code above in your browser using DataLab