View source: R/traits_from_qsm.R
| get_primary_branches | R Documentation |
Extract primary branches from a QSM by filtering out the the trunk, and identifying all cylinders where 'branching_order == 1' and are attached to the trunk. Returns a tibble containing the basal diameter and height of attachment points.
get_primary_branches(qsm)
qsm |
a QSM loaded using '[load_qsm()]'. |
A tibble with one row per primary branch containing:
Character string ("branches").
Basal diameter of the branch (cm).
Height of branch attachment (m).
Placeholder column (currently 'NA').
qsm_file = system.file("extdata", "tree_0744_qsm.txt", package='tReeTraits')
qsm = load_qsm(qsm_file)
primary_branches = get_primary_branches(qsm)
#number of primary branches
nrow(primary_branches)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.