I am trying to use unionSpatialPolygons() of maptools to eliminate sliver in species range. I want to dissolve tiny sliver polygons in a shapefile to bigger polygons as "Eliminate (Data Management)" of ArcMap does. Whereas I can dissolve polygons that have identical features in the argument "IDs", I cannot dissolve tiny polygons based on some threshold in area. In fact, the argument "threshold" has no effect in the output.
Input data is available here: https://www.dropbox.com/sh/a0x5bbo9u60y7is/AAB6RjXHFQKZv-i-t4JclF3ba?dl=0 p.ranges <- shapefile{raster} (IDs <- p.ranges$style_id) library(maptools) unionSpatialPolygons(p.ranges, IDs = IDs, threshold = 1.5) -- Kumar Mainali Postdoctoral Associate Department of Biology University of Maryland, College Park ᐧ [[alternative HTML version deleted]] ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.