Learn R Programming

treecm (version 1.2.2)

centreOfMassModulus: Computes the modulus of the CM vector

Description

The Centre of Mass vector starts from the tree base and points towards the CM. Its modulus is the distance between the CM (x, y, z) and tree base (0, 0, 0).

Usage

centreOfMassModulus(object)

Arguments

object
an object of CM class

Value

a real number

See Also

Other Stabilization: anchorRange, centreOfMassAngle, getPlinthForce, logPathSelection, toCartesianXYZ

Examples

Run this code
library(treecm)
data(stonePine1TreeData)
vectors <- treeVectors(stonePine1TreeData)
CM <- centreOfMass(object=vectors)
print(centreOfMassModulus(CM))
treeMoment <- buildTreeMomentObject(
 centreOfMassModulus(CM)
 , treeTotalBiomass(stonePine1TreeData)
 , centreOfMassAngle(CM)
 )

Run the code above in your browser using DataLab