Creates an empty `SpatRaster` covering the bounding box of `points`, enlarged by `margin` on each side, with square cells of size `res`. The extent is aligned on multiples of `res`.
Examples
data(soil_metaleurop)
soil_grid(soil_metaleurop, res = 25, margin = 1000)
#> class : SpatRaster
#> size : 415, 401, 1 (nrow, ncol, nlyr)
#> resolution : 25, 25 (x, y)
#> extent : 697600, 707625, 7032150, 7042525 (xmin, xmax, ymin, ymax)
#> coord. ref. : RGF93 v1 / Lambert-93 (EPSG:2154)