bbox_to_polygon: Convert a bbox to sp::polygon, sp::Polygons, or...

Description Usage Arguments Value

Description

Convert a bbox to sp::polygon, sp::Polygons, or sp::SpatialPolygons object

Usage

1
2
3
bbox_to_polygon(bb, projstring = "+proj=longlat +datum=WGS84",
  id = "bbox", output_class = c("SpatialPolygons", "Polygons",
  "Polygon")[1])

Arguments

bb

numeric, a 4-element bbox vector [left, right, bottom, top]

projstring

character sutiable to pass to sp::CRS, by default "+proj=longlat +datum=WGS84"

id

character, the polygon ID, by default 'bbox'

output_class

character, either "SpatialPolygons", "Polygons" or "Polygon"

Value

sp::SpatialPolygons object or NULL


BigelowLab/spnc documentation built on May 5, 2019, 2:45 p.m.