# NOT RUN {
#- import the tree_line_plot dataset
file <- system.file("extdata", "tree_line_plot.laz", package="viewshed3d")
tls <- lidR::readLAS(file,select="xyz")
#- reduce the point cloud density: keep one point in a voxel of 4cm.
sub = viewshed3d::downsample_scene(tls,filter=0.04)
#- plot the downsampled point cloud
lidR::plot(sub)
# }
Run the code above in your browser using DataLab