Description Usage Arguments Value Examples
compute_ba computes Basal Area according to user-specified grouping variables -e.g. Plot, species, etc- and time.
1 2 3 4 5 6 7 8 9 |
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. |
by |
A character vector containing the name of the columns containing the variables -other than census time- according to which the result will be aggregated. Be it plots, subplots or species name... |
size_col |
character containing the name of the tree size measurements column -either circumference or diameter. |
measure_type |
A single character indicating whether tree sizes are given in circumferences -"C"- or diameter -"D"-. |
time_col |
A single character containing the name of the column corresponding to census years |
status_col |
Single character, the name of the column containing (corrected) tree life status |
surface |
Either a scalar containing the surface area of each plot -if they have the same dimensions- or a data.frame of the surface area according to some of the grouping variables -e.g. Plot and subplot. However, defaults to FALSE and in this case, only absolute BA is returned. |
A dataframe containing, for each combination of grouping variables, the plot-level and per-ha basal area for a given census year.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 | data("example_recruits")
ba_plots <- suppressWarnings(compute_ba(example_recruits,
size_col = "size_corr",
measure_type = "C",
time_col = "CensusYear",
by = "Plot",
surface = 1.5625))
ba_taxa <- suppressWarnings(compute_ba(example_recruits,
size_col = "size_corr",
measure_type = "C",
time_col = "CensusYear",
by = c("binomial_name","Plot"),
surface = 1.5625))
str(ba_plots)
head(ba_taxa)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.