Learn R Programming

silviculture (version 0.2.0)

silv_sample_size: Calculates sample size for a random sampling inventory

Description

[Deprecated]

Usage

silv_sample_size(
  x,
  plot_size,
  total_area,
  method = "random",
  max_error = 0.05,
  conf_level = 0.95,
  max_iter = 1000,
  quiet = FALSE
)

Value

SampleSize object

Arguments

x

vector of field survey

plot_size

a numeric vector of length one with plot size in squared meters

total_area

total area of the study area in squared meters

method

sampling method. Available options are random

max_error

maximum allowed error

conf_level

confidence level

max_iter

maximum number of iteration to find the plot size

quiet

if TRUE, messages will be supressed

Examples

Run this code
## pilot inventory measuring 4 plots of 25x25 meters
## total forest area 15 ha
## measured variable (x): basal area per hectare
silv_sample_size(
  x          = c(33, 37.5, 42, 35.2),
  plot_size  = 25 * 25,  # squared plot of 25x25
  total_area = 15 * 1e4, # 15 ha
  max_error  = 0.05,
  conf_level = 0.95,
  max_iter   = 100
)

Run the code above in your browser using DataLab