converts spatial objects as defined in package sp to simpler PBSmapping type dataframes
converts spatial objects as defined in package sp to simpler PBSmapping type dataframes
The PlotPolysOnStaticMap() function currently does not take sp objects directly but instead needs PBSmapping type data.frames. This function converts sp objects into such. THANKS TO Fabio Priuli for a major bug fix w.r.t. holes in spatial polygons!
SpatialToPBS(xy, verbose =0)
Arguments
xy: spatial object, such as SpatialPoints, SpatialPolygons, etc..
verbose: level of verbosity
Returns
list with elements xy = converted object, bb = bounding box, fun = plot function