tlsPlot: Plot _TreeLS_ outputs

Description Usage Arguments Examples

Description

Plot the outputs of TreeLS methods on the same scene using rgl.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
tlsPlot(..., fast = FALSE, tree_id = NULL, segment = NULL)

add_segmentIDs(x, las, ...)

add_treeIDs(x, las, ...)

add_treeMap(x, las, ...)

add_treePoints(x, las, color_func = pastel.colors, ...)

add_stemPoints(x, las, ...)

add_stemSegments(x, stems_data_table, color = "white", fast = FALSE)

add_tlsInventory(x, inventory_data_table, color = "white", fast = FALSE)

Arguments

...

in tlsPlot: any object returned from a TreeLS method. In the add_* methods: parameters passed down to 3D plotting rgl functions.

fast

logical, use TRUE to plot spheres representing tree diameters or FALSE to plot detailed 3D cylinders.

tree_id

numeric - plot only the tree matching this tree id.

segment

numeric - plot only stem segments matching this segment id.

x

output from plot or tlsPlot

las

LAS object.

color_func

color palette function used in add_treePoints.

stems_data_table, inventory_data_table

data.table objects generated by stemSegmentation and tlsInventory.

color

color of 3D objects.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
file = system.file("extdata", "pine.laz", package="TreeLS")
tls = readTLS(file) %>%
  tlsNormalize %>%
  stemPoints(stm.hough())

dmt = shapeFit(shape = 'circle', algorithm='ransac', n=20)
inv = tlsInventory(tls, d_method = dmt)

### quick plot
tlsPlot(tls, inv)

### customizable plots
x = plot(tls)
add_stemPoints(x, tls, color='red', size=3)
add_tlsInventory(x, inv, color='yellow')
add_segmentIDs(x, tls, color='white', cex=2, pos=4)

TreeLS documentation built on Aug. 26, 2020, 5:14 p.m.