mtgcomponents: Components of upper scale of a vertex

Description Usage Arguments Details Value Author(s) References See Also Examples

View source: R/mtgcomponents.R

Description

For a vertex in an object of class foldermtg, computes its decomposition into vertices of an upper scale.

Usage

1
mtgcomponents(x, vertex, scale)

Arguments

x

an object of class foldermtg.

vertex

character. The identifier of a vertex. These identifiers are the rownames of the data frame x$topology.

scale

integer. The scale of the components of vertex which will be returned.

Details

If vertex is a vertex of scale i, then scale (the scale of the returned components of vertex) must be higher than i. For example, if vertex is a vertex of scale 2, then scale > 2, for instance scale = 3. The returned components are then vertices of scale 3 which have a decomposition relationship with vertex.

Value

A character vector, containing the idendifiers of the components of vertex.

If there is no component, then the returned vector is empty.

Author(s)

Rachid Boumaza, Pierre Santagostini, Smail Yousfi, Gilles Hunault, Sabine Demotes-Mainard

References

Cokelaer, T. and Pradal, C. (2010). MTG user guide (Functions for moving in MTGs)

See Also

read.mtg: reads a MTG file and builds an object of class foldermtg.

mtgorder, mtgrank.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
mtgfile <- system.file("extdata/plant1.mtg", package = "dad")
xmtg <- read.mtg(mtgfile)

# Vertex of class "P" (plant, of scale 1), components of class 2 (axes: "A")
mtgcomponents(xmtg, vertex = "v01", scale = 2)

# Vertex of class "P" (plant, of scale 1), components of class 3 ("O", "M" and "I")
mtgcomponents(xmtg, vertex = "v01", scale = 3)

# Vertex of class "A" (stem, of scale 2), components of class 3 ("O", "M" and "I")
mtgcomponents(xmtg, vertex = "v12", scale = 3)

dad documentation built on March 16, 2021, 9:05 a.m.