standingTree-methods {sampSurf}R Documentation

Methods for standingTree Object Construction in Package sampSurf

Description

There are currently two available methods for the generic standingTree. These methods generate objects of class "standingTree" that are valid objects. This is the preferred method for generating such objects, rather then using new.

Methods

signature(object = "missing")

This constructor will be used when the signature argument is "missing." When object is missing, the taper data is generated from the internal taper function between the buttDiam (derived internally from taper data) and topDiam diameters for the tree, in nSegs sections. The taper function used is documented in “The Stem Class” vignette and references for "standingTree." The following arguments are part of the function call; all arguments with the same names as class slots are also defined in the class definition (and may be stored differently than the arguments).

usage...

standingTree(
             dbh = 20,                     #cm
             topDiam = 0,                  #cm
             height = 15,                  #meters
             nSegs = 20,
             solidType = 3,                #must have some taper model for butt diam
             treeVol = NULL,
             surfaceArea = NULL,
             biomass = NA,
             vol2wgt = NA,
             carbon = NA,
             wgt2carbon = NA,
             centerOffset = c(x=0, y=0),   #tree base-pith center offset
             species = '',
             treeID = paste('tree',.StemEnv$randomID(),sep=':'),
             description = NULL,
             userExtra = NULL,
             units = 'metric',
             spUnits = CRS(projargs=as.character(NA)),
             runQuiet = TRUE,
             ... )
signature(object = "data.frame")

When object is a "data.frame," then it is assumed that the data frame contains the taper data in the form of diameters and heights (as columns with labels "diameter" and "height", respectively), with diameters in the same units as height. All arguments except those listed below are the same as in the previous constructor...

usage...

standingTree(object
             solidType = NULL,             #defaults to null for passed taper
             treeVol = NULL,
             surfaceArea = NULL,
             biomass = NA,
             vol2wgt = NA,
             carbon = NA,
             wgt2carbon = NA,
             centerOffset = c(x=0, y=0),   #tree base-pith center offset
             species = '',
             treeID = paste('tree',.StemEnv$randomID(),sep=':'),
             description = NULL,
             userExtra = NULL,
             units = 'metric',
             spUnits = CRS(projargs=as.character(NA)),
             runQuiet = TRUE,
             ...)

Note

It may not be immediately apparent how the taper data in the data frame is to be structured if you have this data available either from measurements, or from a different taper equation. The best way to check this out is to simply create a dummy "standingTree" object and then show or print it for a summary, which will show the first few records of the structure. If that is not enough, then you can look at the structure with the @ operator applied to the object's taper slot. Please also see the vignette mentioned above. Remember, the diameters in the taper data frame are expected to be in the same units as length for a data frame.

Author(s)

Jeffrey H. Gove

See Also

The "standingTree" class and the standingTree generic.

Examples

#create a standingTree object and show it
st = standingTree(dbh=20, solidType=2.1)
summary(st)

[Package sampSurf version 0.7-4 Index]