errors: error functions

Description Usage Arguments Details Value Functions Disclaimer

Description

Functions to express the uncertainty of a sample.

Usage

1
2
3
sem(x, na.rm = TRUE)

conf(x, na.rm = TRUE, confidence = 0.99)

Arguments

x

a numeric vector

na.rm

logical flag whether to remove NA values

confidence

the desired confidence

Details

These are helper functions for drawing error bars on plots. They both calculate a measure of uncertainty and return a single number, which is the width of the "uncertainty interval". Add and subtract this unmber to the sample mean to get the position of the error bars.

Value

a single numeric

Functions

Disclaimer

The confidence interval is calculated with a t distribution. I don't understand how the confidence interval is calculated.


olobiolo/acutils documentation built on Nov. 28, 2021, 9:35 p.m.