Learn R Programming

ForestElementsR (version 2.0.1)

ytable_lookup: Look Up Values From Yield Tables

Description

Provide yield table values for a given age and site index. If necessary, values are linearly inter- and extrapolated.

Usage

ytable_lookup(age, si, variable, ytable)

Value

The requested yield table value

Arguments

age

Stand age (years)

si

Site index (according to the yield table of interest's (ytable) site index definition). If si is outside the yield table's coverage, an extrapolated value is returned, and a warning is raised.

variable

Name of the variable to be looked up. If the name is not one of the variable names available in the fe_yield_table object, the function will terminate with an error.

ytable

A yield table, must be an fe_yield_table object

See Also

Other yield table functions: fe_yield_table(), plot.fe_yield_table(), si_to_mai_age(), si_to_mai_max(), site_index(), stocking_level(), yield_tables_for_species, ytable_age_slice(), ytable_max_slice()

Examples

Run this code
  age <- 72
  si  <- 3.2

  ytable_lookup(
    age, si, "h_q_m", fe_ytable_spruce_gehrhardt_moderate_1921
  )

  ytable_lookup(
    age, si, "v_m3_ha", fe_ytable_spruce_gehrhardt_moderate_1921
  )

  ytable_lookup(
    age, si, "mai_m3_ha_yr", fe_ytable_spruce_gehrhardt_moderate_1921
  )


Run the code above in your browser using DataLab