Skip to contents

Helper function used to retrieve the bounding box of a specified spatial file recognized by sf or raster: the function reads the extent using sf::st_bbox()

Usage

bbox_from_file(file_path, crs_out)

Arguments

file_path

character path of a spatial file.

crs_out

(crs | character) crs of the desired output projection, or string coercible to it using sf::st_crs() (e.g., WKT or numeric EPSG code)

Note

License: GPL 3.0

Author

Lorenzo Busetto, phD (2017)

Luigi Ranghetti, phD (2017)