
Growth and Mortality Analysis
growth-mortality-analysis.RmdIntroduction
This vignette demonstrates how to compute tree growth rates and mortality/recruitment statistics for permanent forest plots with multiple censuses.
Two main functions are available:
-
compute_growth(): Calculate diameter growth rates between censuses -
compute_mortality(): Calculate mortality and recruitment rates
Both functions automatically fetch data from the database and only require plot identifiers as input.
Computing Growth Rates
Basic Usage
# Connect to database
con <- call.mydb()
# Compute growth by plot name
growth <- compute_growth(plot_names = "mbalmayo001", con = con)
# Or by plot ID
growth <- compute_growth(plot_ids = c(1, 2, 3), con = con)Understanding the Output
The function returns a list with two components:
# Summary statistics per plot and census interval
growth$summary
# Individual-level growth data
growth$individualsSummary columns:
-
plot_name: Plot identifier -
census_pair: Census interval (e.g., “1-2” for first to second census) -
n_individuals: Total individuals measured in both censuses -
n_valid: Individuals with valid growth measurements -
n_excluded: Individuals excluded due to measurement errors -
mean_growth_mm_yr: Mean diameter growth rate (mm/year) -
sd_growth_mm_yr: Standard deviation of growth -
median_growth_mm_yr: Median growth rate -
mean_dbh_1_mm: Mean DBH at first census (mm) -
mean_dbh_2_mm: Mean DBH at second census (mm) -
mean_interval_years: Mean time between censuses (years)
Growth Calculation Methods
Two methods are available:
# Incremental growth (default): (DBH2 - DBH1) / time
growth_inc <- compute_growth(plot_ids = 1, method = "I")
# Exponential growth: (log(DBH2) - log(DBH1)) / time
growth_exp <- compute_growth(plot_ids = 1, method = "E")Adjusting Quality Control Parameters
growth <- compute_growth(
plot_ids = 1,
mindbh = 100, # Minimum DBH in mm (default: 100)
err.limit = 4, # Error limit for negative growth detection (default: 4)
maxgrow = 75 # Maximum valid growth in mm/year (default: 75)
)Quality control:
- Trees with DBH <
mindbhare excluded - Extreme negative growth (measurement errors) is detected using a statistical model
- Growth rates >
maxgrowmm/year are flagged as errors
Summary Only
To get only summary statistics without individual data:
growth <- compute_growth(
plot_ids = 1,
return_individual = FALSE
)Computing Mortality and Recruitment
Basic Usage
# Compute mortality by plot name
mort <- compute_mortality(plot_names = "mbalmayo001", con = con)
# Or by plot ID
mort <- compute_mortality(plot_ids = c(1, 2, 3), con = con)Understanding the Output
The function returns a list with three components:
# Summary statistics
mort$summary
# List of individuals that died
mort$dead_individuals
# List of newly recruited individuals
mort$recruitsSummary columns:
-
plot_name: Plot identifier -
census_pair: Census interval -
N_outset: Number of individuals at start of interval -
N_dead: Number of deaths -
N_survivor: Number of survivors -
N_recruits: Number of new recruits -
mortality_rate: Exponential mortality rate -
mortality_percent_yr: Annual mortality percentage -
recruitment_rate: Exponential recruitment rate -
recruitment_percent_yr: Annual recruitment percentage -
mean_interval_years: Time between censuses -
mean_dbh_dead_cm: Mean DBH of dead trees (cm) -
mean_dbh_recruit_cm: Mean DBH of recruits (cm)
Mortality Rate Calculation
Mortality rate is calculated using the exponential model:
Where: - = number of individuals at start - = number of survivors - = time interval in years
Annual mortality percentage is:
Examining Recruits
# View recruited individuals
mort$recruits
# Size distribution of recruits
hist(mort$recruits$dbh_at_recruitment_cm)Complete Workflow Example
library(CafriplotsR)
library(dplyr)
# Connect
con <- call.mydb()
# Define plots to analyze
my_plots <- c("site_A_plot1", "site_A_plot2", "site_B_plot1")
# Compute growth
growth <- compute_growth(plot_names = my_plots, con = con)
# View growth summary
growth$summary %>%
arrange(plot_name, census_pair)
# Compute mortality
mort <- compute_mortality(plot_names = my_plots, con = con)
# Compare mortality across plots
mort$summary %>%
select(plot_name, census_pair, mortality_percent_yr, recruitment_percent_yr) %>%
arrange(plot_name)
# Identify species with high mortality
mort$dead_individuals %>%
count(tax_sp_level, sort = TRUE)
# Clean up
cleanup_connections()Troubleshooting
“Need at least 2 censuses”
This error occurs when the selected plots don’t have multiple census records:
# Check if your plot has multiple censuses
query_result <- query_plots(
plot_names = "your_plot",
show_multiple_census = TRUE,
extract_individuals = FALSE
)
# Look at census_features to see available censuses
query_result$census_featuresNo valid measurements
If growth calculations return few valid measurements, check:
-
Minimum DBH threshold: Lower
mindbhif needed - Date information: Ensure census dates are recorded in the database
- Measurement quality: Review excluded individuals in the output
# Check individual results for exclusions
growth <- compute_growth(plot_ids = 1)
table(growth$individuals$accepted_growth)References
Growth trimming methodology adapted from:
- CTFS R Package: http://ctfs.si.edu/Public/CTFSRPackage/
Mortality rate calculations follow standard forest dynamics methodology as described in:
- Sheil, D., & May, R. M. (1996). Mortality and recruitment rate evaluations in heterogeneous tropical forests. Journal of Ecology, 84(1), 91-100.