View source: R/plotting_metrics_pc.R
plot_dab_fit_pcs | R Documentation |
dab_pc
functionCalculates the dab and saves the figures acquired when running
dab_pc
on multiple tree point clouds in a folder. Use different
values for the thresholdbuttress and maxbuttressheight parameter to optimise
dab calculation for your tree point clouds.
plot_dab_fit_pcs(
PCs_path,
extension = ".txt",
OUT_path = "./",
thresholdbuttress = 0.001,
maxbuttressheight = 7,
slice_thickness = 0.06,
functional = TRUE,
concavity = 4,
dtm = NA,
r = 5,
plotcolors = c("#000000", "#808080", "#1c027a", "#08aa7c", "#fac87f")
)
PCs_path |
A character with the path to the folder that contains the tree point clouds. |
extension |
A character refering to the file extension of the point cloud files (default=".txt"). Can be ".txt", ".ply" or ".las". |
OUT_path |
A character with the path to the folder where the figures should be saved (default = current folder). |
thresholdbuttress |
Numeric value (default=0.001). Parameter of the
|
maxbuttressheight |
Numeric value (default=7). Parameter of the
|
slice_thickness |
Numeric value (default = 0.06) that determines the thickness of the slice which is used to measure the diameter. |
functional |
Logical (default=FALSE), indicates if the functional diameter should be calculated. |
concavity |
Numeric value (default=4) concavity for the computation of
the functional diameter using a concave hull based on
|
dtm |
The digital terrain model (default = NA), parameter of
|
r |
Numeric value (default=5) r, parameter of
|
plotcolors |
list of three colors for plotting. Only relevant when plot = TRUE. The stem points above buttresses, stem points at breast height, fitted circle, the concave hull and the estimated center are colored by the first, second, third, fourth and fifth element of this list respectively. |
Uses read_tree_pc
to read the point clouds and
dab_pc
with parameter plot = TRUE to calculate the dab and plot
the circle fitting.
A list with in the first element a numeric containing the dab values for each tree point cloud, the second element the residuals on the circle fittings, the third element the functional diameters. In the fourth element there is the list with the plots. Figures are also saved in the output folder.
## Not run:
# Calculate DABs with default settings and save circle fitting figures
dab_values <- plot_dab_fit_pcs(
PCs_path = "path/to/folder/PCs/",
extension = ".txt",
OUT_path = "path/to/figure/folder/"
)
# Calculate DABs with non-default settings and save circle fitting figures
dab_values <- plot_dab_fit_pcs(
PCs_path = "path/to/folder/PCs/",
extension = ".txt",
OUT_path = "path/to/figure/folder/",
thresholdbuttress = 0.002,
maxbuttressheight = 5
)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.