Skip to contents

Get raster of cover classification from lidar points

Usage

rasterize_lidar_cover_class(
  las = NULL,
  res = 1,
  fill.holes = TRUE,
  filename = NULL
)

Arguments

las

A lidR::LAScatalog-class() object, or a character vector with paths to LAS/LAZ objects.

res

Resolution of the resulting raster.

fill.holes

Logical. Try to fill holes in lidar point classification.

filename

Character. Output filename. Note that if a file already exists with that name, it will be overwritten.

Value

A SpatRaster with the classification of cover types: 2 = ground (including low vegetation < 1m) 4 = high vegetation (> 1m) 6 = buildings 9 = water and NA values. Note that points classified as bridges (class 17) will be reclassified as ground.

Examples

if (FALSE) {
pza <- system.file("extdata", "PlazaNueva.laz", package = "CityShadeMapper")
pza.cover <- rasterize_lidar_cover_class(pza)
}