Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

average_tree_curve

Generate the curve of a forest's average tree using the Kozak taper model


Description

Generate a ggplot curve of a forest's average tree using the Kozak taper model (Kozak, Munro and Smith, 1969).

Usage

average_tree_curve(
  df,
  d,
  dbh,
  h,
  th,
  facet = NA,
  color = NA,
  mirror = TRUE,
  eq = TRUE
)

Arguments

df

A data frame.

d

Quoted name of the section diameter variable, in cm.

dbh

Quoted name of the diameter at breast height variable, in cm.

h

Quoted name of the section height variable, in meters.

th

Quoted name of the total height variable, in meters.

facet

Optional argument. If supplied with the Quoted name of a factor variable(s), this variable is used to divide the plot into facets. Default: NA.

color

Quoted name of a variable. If supplied, this variable will be used to classify the data by color. Default: NA.

mirror

if TRUE, the plot will be mirrored, to resemble the shape of a tree. Default: TRUE

eq

if TRUE, Kozak's taper model is adjusted and the equation is shown on the plot. Default TRUE

Value

A ggplot object.

Author(s)

Sollano Rabelo Braga sollanorb@gmail.com

References

Kozak, A., Munro, D. D. and Smith, J. H. G. (1969) Taper Functions and their Application in Forest Inventory, The Forestry Chronicle, 45, pp. 278–283.

Examples

library(forestmangr)
data("exfm7")
exfm7

# Get the data's average tree curve inserting the section diameter and height, total height
# and dbh variables: 
average_tree_curve(df = exfm7, d = "di_wb", dbh = "DBH", h = "hi", th = "TH")

# It's possible to get the average tree curve of each strata with the facet argument,
# and divide the data by color with the color argument:
average_tree_curve(df=exfm7,d="di_wb",dbh="DBH",h="hi",th="TH",facet="STRATA",color="GENCODE")

forestmangr

Forest Mensuration and Management

v0.9.3
MIT + file LICENSE
Authors
Sollano Rabelo Braga [aut, cre, cph], Marcio Leles Romarco de Oliveira [aut], Eric Bastos Gorgens [aut]
Initial release
2021-01-24

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.