get_plots_cbh_LAD {LadderFuelsR}R Documentation

Plots the Canopy Base Height (CBH) based on the maximum LAD percentage criterium

Description

This function plots the CBH of a segmented tree based on the fuel layer with the maximum LAD percentage.

Usage

get_plots_cbh_LAD(LAD_profiles, cbh_metrics)

Arguments

LAD_profiles

Original tree Leaf Area Density (LAD) profile (output of [lad.profile()] function in the leafR package). An object of the class text.

cbh_metrics

CBH metrics based on three criteria: maximum LAD percentage, maximum distance and last distance. (output of [get_cbh_metrics()] function). An object of the class text.

Value

A plot drawing the Canopy Base Height (CBH) of the fuel layer with the maximum Leaf Area Density (LAD) percentage.

Author(s)

Olga Viedma, Carlos Silva and JM Moreno

See Also

get_layers_lad

Examples

library(ggplot2)
library(dplyr)

# LAD profiles derived from normalized ALS data after applying [lad.profile()] function
LAD_profiles <- read.table(system.file("extdata", "LAD_profiles.txt", package = "LadderFuelsR"),
header = TRUE)
LAD_profiles$treeID <- factor(LAD_profiles$treeID)

# Before running this example, make sure to run get_cbh_metrics().
if (interactive()) {
cbh_metrics <- get_cbh_metrics()
LadderFuelsR::cbh_metrics$treeID <- factor(LadderFuelsR::cbh_metrics$treeID)

trees_name1 <- as.character(cbh_metrics$treeID)
trees_name2 <- factor(unique(trees_name1))

# Generate plots for fuels LAD metrics
plots_trees_LAD <- get_plots_cbh_LAD(LAD_profiles, cbh_metrics)
}

[Package LadderFuelsR version 0.0.4 Index]