Remove holes from a SpatialPolygons object. Note that this function
differs from the function findHoles in that
it only removes holes contained within the polygon itself, not gaps between
the polygon and region boundaries
Usage
rm_holes(my_poly, poly_name = "notSpecified")
Arguments
my_poly
SpatialPolygon object
poly_name
character string to name polygon (defaults to "notSpecified")
# NOT RUN {with_holes <- bg_water[2]
plot(with_holes, col = "blue", main = "Polygon with Holes")
no_holes <- rm_holes(with_holes)
plot(no_holes, col = "blue", main = "Holes removed")
# }