calculate_dendrometry: Calculates and aggregates parameters on dendrometry of trees

View source: R/calculate_dendrometry.R

calculate_dendrometryR Documentation

Calculates and aggregates parameters on dendrometry of trees

Description

This function calculates additional variables and makes aggregations of individual tree measures on the levels of

  • plot and year

  • plot, tree species and year

  • diameter class, plot and year

  • diameter class, plot, tree species and year

and it makes aggregations of volume data on logs on the levels of

  • decay stage, plot and year

  • decay stage, plot, tree species and year

Usage

calculate_dendrometry(
  data_dendro,
  data_deadwood,
  data_shoots,
  height_model,
  plotinfo
)

Arguments

data_dendro

dataframe on tree measures with variables plot_id, plottype, tree_measure_id, date_dendro, dbh_mm, height_m, species, alive_dead, decaystage, period, old_id, year, subcircle, plotarea_ha,... (output of function load_data_dendrometry())

data_deadwood

dataframe on logs with variables plot_id, plottype, date_dendro, species, decaystage, calc_volume_m3, period and year (output of function load_data_deadwood())

data_shoots

dataframe on shoots as given from the function load_data_shoots()

height_model

dataframe with model containing 'exp' or 'ln', coefficients P1 and P2 to calculate height model for each combination of species, forest_reserve, period and plottype. Height models in .xlsx generated by Fieldmap can be grouped in a dataframe using function load_height_models()

plotinfo

dataframe on surveyed plots with variables plot_id, plottype, forest_reserve, survey_trees, survey_deadw, period and year_dendro (output of function load_plotinfo())

Value

List of dataframes that are mentioned in the above description

Examples

library(forrescalc)
# (add path to your own fieldmap database here)
path_to_fieldmapdb <-
  system.file("example/database/mdb_bosres.sqlite", package = "forrescalc")

data_dendro <- load_data_dendrometry(path_to_fieldmapdb)
data_deadwood <- load_data_deadwood(path_to_fieldmapdb)
data_shoots <- load_data_shoots(path_to_fieldmapdb)
# omit argument 'example_dataset = TRUE' below to use all height models
height_model <- load_height_models(example_dataset = TRUE)
plotinfo <- load_plotinfo(path_to_fieldmapdb)
calculate_dendrometry(
  data_dendro, data_deadwood, data_shoots, height_model, plotinfo)


inbo/forrescalc documentation built on Sept. 28, 2024, 11:45 a.m.