mtgorder {dad} | R Documentation |
Branching order of vertices
Description
Computes the branching order of vertices contained in an object of class foldermtg
. The order of a vertex is the number of the column of topology
, which contains this vertex.
Usage
mtgorder(x, classes = "all", display = FALSE)
Arguments
x |
an object of class |
classes |
character vector. The classes of entities for which the branching order is computed. If omitted, the branching orders are computed for all entities. |
display |
logical. If |
Details
Returns x
after appending the branching orders of the vertices of the classes given in the argument classes
. The branching orders
are appended to the data frames containing the vertices (one data frame per class) and the values of their corresponding features.
Value
Returns an object of class foldermtg
, that is a list of data frames.
Author(s)
Rachid Boumaza, Pierre Santagostini, Smail Yousfi, Gilles Hunault, Sabine Demotes-Mainard
References
Pradal, C., Godin, C. and Cokelaer, T. (2023). MTG user guide
See Also
read.mtg
: reads a MTG file and builds an object of class foldermtg
.
Examples
mtgfile <- system.file("extdata/plant1.mtg", package = "dad")
xmtg <- read.mtg(mtgfile)
# The branching orders
ymtg <- mtgorder(xmtg)
print(ymtg)
# Add the branching orders to the 'foldermtg'
zmtg <- mtgorder(xmtg, display = TRUE)
print(zmtg)