ytable_age_slice: Take an Age Slice out of an fe_yield_table_object

View source: R/fe_yield_table_methods.R

ytable_age_sliceR Documentation

Take an Age Slice out of an fe_yield_table_object

Description

Age slices out of yield tables are typically required for finding out the site index for a given age-height pair, or for extracting a yield table value when age and site index are given.

Usage

ytable_age_slice(age, variable, ytable)

Arguments

age

The age (in years) for which the time slice has to be drawn

variable

Name of the yield table variable for which the slice is to be taken

ytable

An object of class fe_yield_table

Details

If the age provided by the user is not directly contained in the table, linear interpolation and also extrapolation is used for obtaining the age slice. Currently, this is only done inside the general age span covered by the table (slot $age_coverage of the yield table object). For ages outside this range, the slice is given for the nearest covered age extreme, and a warning is issued.

Value

A (named) vector representing the vertical slice of the desired yield table variable. The names are the site indexes as defined in the yield table's element $site_index (in the same order) with the prefix "si_".

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_lookup(), ytable_max_slice()

Examples

  # Get the yield table heights of the Wiedemann 1943 Scots pine table at age
  # 73
  ytable_age_slice(
    fe_ytable_pine_wiedemann_moderate_1943,
    age = 73,
    variable = "h_q_m"
  )



ForestElementsR documentation built on April 3, 2025, 7:47 p.m.