bbox_from_vector.Rd
This works automatically with raster extents or sf::bbox
bbox_from_vector(
v,
crs,
x_name_min = "xmin",
y_name_min = "ymin",
x_name_max = "xmax",
y_name_max = "ymax"
)
vector with names (xmin,ymin,ymax,ymax)
character
character
character
character
sf object representing bbox
if (FALSE) {
library(sf)
shp_trees <- st_read('https://www.donneesquebec.ca/recherche/dataset/bc5afddf-9439-4e96-84fb-f91847b722be/resource/bbdca0dd-82df-42f9-845b-32348debf8ab/download/vdq-arbrepotentielremarquable.geojson')
rasterKDECentroids <- st_kde(shp_trees , cellsize = 0.001, bandwith =c(.001, .001 ) )
bbox_from_vector(extent(rasterKDECentroids) , crs=4326)
}