Functions for Forest Mensuration and Management

Set of functions for processing forest inventory data with methods such as simple random sampling, stratified random sampling and systematic sampling. There are also functions for yield and growth predictions and model fitting, linear and non linear grouped data fitting, and statistical tests.


Set of functions for processing forest inventory and surveying calculations. There are also functions for yield and growth predictions and model fitting (Clutter), linear and nonlinear grouped data fitting functions, and statistical tests such as Graybill's F and indentity model test.


You can install forestmangr from github with:




Now, we can fit a model for S estimatation. With nls_table, we can fit a non-linear model, extract it's coefficients, and merge it with the original data in one line. Here we'll use Chapman & Richards model:

age_i <- 64
exfm16_fit <- exfm17 %>%
  nls_table(DH ~ b0 * (1-exp(-b1* age))^b2, mod_start = c( b0=23, b1=0.03, b2 = 1.3), output="merge") %>% 
  mutate(site = DH *( ( (1- exp( -b1/age ))^b2 ) / (( 1 - exp(-b1/age_i))^b2 ))) %>% 

Now, to fit Clutter's model, we can use the fit_clutter function, indicating the DH, B, V, S and Plot variable names:

coefs_clutter <- fit_clutter(exfm17_fit, "age", "DH", "B", "V", "site", "plot")

Now let's say we wanted to do a Simple Random Sampling Forest Inventory, with 20% as a accepted error. First, let's load the package and some data:


First we should try a pilot inventory, to see if the number of plots sampled is enough for reaching the desired error:

sprs(exfm3, "VWB", "PLOT_AREA", "TOTAL_AREA", error = 20, pop = "fin")

We can see that we have 10 plots, but 15 more are needed if we want a minimum of 20% error. The exfm4 data has new samples, that we now can use to run a definitive inventory:

sprs(exfm4, "VWB", "PLOT_AREA", "TOTAL_AREA", error = 20, pop = "fin")

The exfm2 data has a strata variable. Say we wanted to run a SRS inventory for every stand. We can do this with the grupos argument:

sprs(exfm2, "VWB", "PLOT_AREA", "STRATA_AREA", "STRATA", error = 20, pop = "fin")

We can also run a stratified random sampling inventory with this data:

strs(exfm2, "VWB", "PLOT_AREA", "STRATA_AREA", "STRATA", error = 20, pop = "fin")


This project is licensed under the MIT License - see the file for details


  • This project is being done on the Forest Management Lab, DEF, UFVJM - Diamantina/Minas Gerais - Brazil.

  • This project came to be as a mean to make the life of a forestry engeneer a little easier and pratical. We'd like to thank everyone at UFVJM that has in anyway helped this project grow.

  • We'd like to thank UFVJM, FAPEMIG, CNPq e CAPES fo rthe support.


forestmangr development

forestmangr 0.9.0

  • release

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.


0.9.1 by Sollano Rabelo Braga, 2 months ago

Report a bug at

Browse source code at

Authors: Sollano Rabelo Braga [aut, cre, cph] , Marcio Leles Romarco de Oliveira [aut] , Eric Bastos Gorgens [aut]

Documentation:   PDF Manual  

MIT + file LICENSE license

Imports dplyr, ggplot2, ggthemes, tidyr, broom, purrr, plyr, tibble, systemfit, ggpmisc, rlang, utils, car, stats, methods, magrittr, minpack.lm, FinCal, formattable, scales, ggdendro, gridExtra

Suggests covr, knitr, rmarkdown

See at CRAN