AMBarbosa / fuzzySim

Fuzzy Similarity in Species Distributions
http://fuzzysim.r-forge.r-project.org/
GNU General Public License v3.0
0 stars 0 forks source link

cleanCoords(uncert.na.pass = ) is removing NAs if TRUE and if FALSE #1

Closed NACasillas closed 1 week ago

NACasillas commented 2 weeks ago

I'm trying to remove the occurrences which have uncertainty of more than 10,000 meters without removing occurences where the uncertainty is NA. I have tried setting uncert.na.pass to both TRUE and to FALSE, but both return the same result. I've attached my Occs file. Occs.csv

Here is my code:

Console when uncert.na.pass = TRUE:

  > Occs <- fuzzySim::cleanCoords(Occs, coord.cols = c("decimalLongitude", "decimalLatitude"), uncert.col = "CoordinateUncertaintyInMeters", uncert.limit = 10000, uncert.na.pass = TRUE)
  645 rows in input data
  645 rows after 'rm.dup'
  645 rows after 'rm.equal'
  645 rows after 'rm.imposs'
  645 rows after 'rm.missing.any'
  645 rows after 'rm.zero.any'
  645 rows after 'rm.imprec.any'
  265 rows after 'rm.uncert' (with uncert.limit=10000 and uncert.na.pass=TRUE)

Console when uncert.na.pass = FALSE:

> Occs <- fuzzySim::cleanCoords(Occs, coord.cols = c("decimalLongitude", "decimalLatitude"), uncert.col = "CoordinateUncertaintyInMeters", uncert.limit = 10000, uncert.na.pass = FALSE)
645 rows in input data
645 rows after 'rm.dup'
645 rows after 'rm.equal'
645 rows after 'rm.imposs'
645 rows after 'rm.missing.any'
645 rows after 'rm.zero.any'
645 rows after 'rm.imprec.any'
265 rows after 'rm.uncert' (with uncert.limit=10000 and uncert.na.pass=FALSE)
AMBarbosa commented 2 weeks ago

What version of fuzzySim are you using? I don't get the same results with your Occs table... Try reinstalling fuzzySim to get an updated version of the package.

NACasillas commented 1 week ago

Oops! I wasn't updated. It's working properly now. Thanks!