summarize_systematic: Summarize systematic sample

Description Usage Arguments Value Author(s) Examples

View source: R/systematic.R

Description

Summarizes population-level statistics for systematic sample data. The calculations are derived from Chapter 3 in Avery and Burkhart's (1967) Forest Measurements, Fifth Edition. The variance terms refer to the variance of the mean, hence the sampleSize terms in the denominators.

Usage

1
2
summarize_systematic(data, attribute = 'attr', 
                            popSize = NA, desiredConfidence = 0.95)

Arguments

data

data frame or vector containing observations of variable of interest. Variable of interest must already be expanded to the level of interest (e.g. stand-level).

attribute

character name of attribute to be summarized. Must be defined if data is input as a data frame.

popSize

numeric population size. Defaults to NA (unknown popSize).

desiredConfidence

numeric desired confidence level (e.g. 0.9).

Value

a data frame of population mean, variance, standard error, and high and low confidence limits.

Author(s)

Karin Wolken

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
## Not run: 

# See Forest Sampling vignette for more details

# Data frame input data can be expressed as:

trainingData <- data.frame(bapa = c(120, 140, 160, 110, 100, 90),
                           plots = c(1, 2, 3, 4, 5, 6))
attribute = 'bapa'
desiredConfidence = 0.9

# Vector input data can be expressed as:

vector <- c(120, 140, 160, 110, 100, 90)


## End(Not run)

SilviaTerra/forestsamplr documentation built on Jan. 3, 2020, 2:33 p.m.