points2DSM | R Documentation |
Creates a Digital Surface Model from a LAS object. From version 4.0.0 relies on rasterize_canopy
.
Maintained for backward compatibility but a direct call to this function
should be preferred. Raster extent is specified by the coordinates of lower
left and upper right corners. Default extent covers
the full range of points, and aligns on multiple values of the resolution.
Cell value is the maximum height of points contained in the cell.
points2DSM(.las, res = 1, xmin, xmax, ymin, ymax)
.las |
|
res |
numeric. raster resolution |
xmin |
numeric. lower left corner easting coordinate for output raster. |
xmax |
numeric. upper right corner easting coordinate for output raster. |
ymin |
numeric. lower left corner northing coordinate for output raster. |
ymax |
numeric. upper right corner northing coordinate for output raster. |
A SpatRaster object.
points2DTM
for Digital Terrain Model computation.
# load LAS file
LASfile <- system.file("extdata", "las_chablais3.laz", package="lidaRtRee")
las_chablais3 <- lidR::readLAS(LASfile)
# set number of threads
lidR::set_lidr_threads(2)
# create a digital surface model with first-return points, resolution 0.5 m
dsm <- points2DSM(lidR::filter_first(las_chablais3), res = 0.5)
# display raster
terra::plot(dsm)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.