wilson_lower: wilson_lower

Description Usage Arguments Value Notes References

View source: R/utils.R

Description

Calculates lower confidence limits for observed numbers of events using the Wilson Score method [1,2].

Usage

1
wilson_lower(x, n, confidence = 0.95)

Arguments

x

the observed numbers of cases in the samples meeting the required condition; numeric vector; no default

n

the numbers of cases in the samples; numeric vector; no default

confidence

the required level of confidence expressed as a number between 0.9 and 1 or a number between 90 and 100 or can be a vector of 0.95 and 0.998, for example, to output both 95% and 99.8% CIs; numeric; default 0.95

Value

Returns lower confidence limits for observed numbers of events using the Wilson Score method [1,2]

Notes

This is an internal package function that is appropriately called by exported 'phe_' prefixed functions within the PHEindicatormethods package.

wilson_lower and wilson_upper together return symmetric confidence intervals, therefore for a specified confidence level, α, the probability that, by chance, the lower limit returned will be above the true underlying value, is α/2.#'

References

[1] Wilson EB. Probable inference, the law of succession, and statistical inference. J Am Stat Assoc; 1927; 22. Pg 209 to 212.
[2] Newcombe RG, Altman DG. Proportions and their differences. In Altman DG et al. (eds). Statistics with confidence (2nd edn). London: BMJ Books; 2000. Pg 46 to 48.

————————————————————————————————


PHEindicatormethods documentation built on July 1, 2020, 6:01 p.m.