treeMap.positions: Convert a tree map to a 2D 'data.table'

Description Usage Arguments Value Examples

View source: R/methods.R

Description

Extracts the tree XY positions from a treeMap output.

Usage

1

Arguments

map

object generated by treeMap.

plot

logical - plot the tree map?

Value

signed data.table of tree IDs and XY coordinates.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
file = system.file("extdata", "pine_plot.laz", package="TreeLS")
tls = readTLS(file) %>%
  tlsNormalize %>%
  tlsSample

x = plot(tls)

map = treeMap(tls, map.hough(h_step = 1, max_h = 4))
add_treeMap(x, map, color='red')

xymap = treeMap.positions(map)

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