View source: R/update_cylinders.R
update_cylinders | R Documentation |
Updates the QSM cylinder data in preparation for radii correction
update_cylinders(cylinder)
cylinder |
QSM cylinder data frame |
Updates parent-child branch and cylinder relationships to fill in any gaps. Four useful QSM metrics developed by Jan Hackenberg are also calculated. Growth length is the length of a parent cylinder, plus the lengths of all of its child cylinders. The segment is a portion of a branch between two branching nodes. The reverse branch order assigns twigs as order 1 and works backwards at each branching junction to the base of the stem, which has the largest reverse branch order. Distance from twig is the average distance to all connected twigs for a given cylinder. Two new metrics, distance from base, and total children, are also calculated.
Returns a data frame
growth_parameter1rTwig
\insertRefgrowth_parameter2rTwig
## TreeQSM Processing Chain
file <- system.file("extdata/QSM.mat", package = "rTwig")
qsm <- import_qsm(file)
cylinder <- qsm$cylinder
cylinder <- update_cylinders(cylinder)
str(cylinder)
## SimpleForest Processing Chain
file <- system.file("extdata/QSM.csv", package = "rTwig")
cylinder <- read.csv(file)
cylinder <- update_cylinders(cylinder)
str(cylinder)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.