compute_mortality: Compute Annual Mortality Rates in Forest Inventories

Description Usage Arguments Value Examples

View source: R/compute_mortality.R

Description

This function computes mortality in forest inventories according to plot if there are several

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
compute_mortality(
  data,
  status_col = "status_corr",
  time_col = ifelse(is.null(getOption("time_col")), "CensusYear",
    getOption("time_col")),
  id_col = ifelse(is.null(getOption("id_col")), "idTree", getOption("id_col")),
  dead_confirmation_censuses = 2,
  byplot = TRUE,
  plot_col = ifelse(is.null(getOption("plot_col")), "Plot", getOption("plot_col")),
  corrected = TRUE
)

Arguments

data

A data.frame containing a time-series tree-wise forest inventory -i.e. every line is a single tree measurement for a single year.

status_col

Character. The name of the column containing tree vital status - 0=dead; 1=alive.

time_col

Character. The name of the column containing census year

id_col

Character. The name of the column containing trees unique ids

dead_confirmation_censuses

Integer, defaults to 2. This is the number of censuses needed to state that a tree is considered dead, if unseen. In Paracou, we use the rule-of-thumb that if a tree is unseen twice, its probability to be actually dead is close to 1. The choice of this value involves that trees unseen during the X-1 last inventories can not be corrected for death, and thus mortality rates should not be calculated for these censuses.

byplot

Logical. If there are several plots in your dataset, the correction is performed by plot, in case these would not be censuses the same years or with the same frequencies one another.

plot_col

Character. The name of the column containing the plots indices.

corrected

Logical. Indicates whether the dataset has been corrected for errors in tree life status; if not it will be corrected beforehand using correct_alive function

Value

A data.frame with absolute and annual mortality rates by plot and census interval.

Examples

1
2
3
4
5
6
7
8
9
data("example_status_corr")
suppressWarnings(compute_mortality(example_status_corr,
status_col="status_corr",
time_col="CensusYear",
id_col="idTree",
dead_confirmation_censuses=2,
byplot = TRUE,
plot_col = "Plot",
corrected = TRUE))

EcoFoG/ForestData documentation built on Jan. 20, 2021, 10:04 a.m.