catalog_boundaries: Computes the polygon that encloses the points

View source: R/catalog_boundaries.R

catalog_boundariesR Documentation

Computes the polygon that encloses the points

Description

Computes the polygon that encloses the points. It reads all the files one by one and computes a concave hull using the st_concave_hull function. When all the hulls are computed it updates the LAScatalog to set the true polygons instead of the bounding boxes.

Usage

catalog_boundaries(ctg, ...)

Arguments

ctg

A LAScatalog

...

propagated to st_concave_hull

Value

A LAScatalog with true boundaries

Non-supported LAScatalog options

The options 'select', 'output files', 'chunk size', 'chunk buffer', 'chunk alignment' are not supported and not respected in 'catalog_boundaries*' because the function must always process by file, without buffer and knows which attributes to load.

Examples

LASfile <- system.file("extdata", "Megaplot.laz", package="lidR")
ctg <- readLAScatalog(LASfile, filter = "-drop_z_below 0.5")
ctg2 <- catalog_boundaries(ctg, concavity = 1, length_threshold = 15)
plot(ctg)
plot(ctg2, add = TRUE)

lidR documentation built on Sept. 8, 2023, 5:10 p.m.