Learn R Programming

brr (version 1.0.0)

FrequentistInference: Frequentist inference about the relative risk

Description

Frequentist confidence intervals about the relative risk: binomial interval (rr_interval_binomial) and Sahai and Khurshid confidence interval (rr_interval_SK)

Usage

rr_interval_SK(x, y, S, T, conf = 0.95)
rr_interval_binomial(x, y, S, T, conf = 0.95)
rr_intervals(x, y, S, T, conf = 0.95)

Arguments

x,y
Observed counts
S,T
sample sizes
conf
confidence level

Value

rr_interval_binomial and rr_interval_SK return the bounds of the confidence interval in a vector, rr_intervals returns a list with the two confidence intervals

Details

The binomial interval (rr_interval_binomial) is the classical confidence interval obtained by conditionning on the sum x+y of the two counts. The same interval is implemented in the rateratio.test package. The Sahai and Khurshid interval (rr_interval_SK) is an unconditional confidence interval. See the reference for more details and a study of its performance.

References

S. Laurent, C. Legrand: A Bayesian framework for the ratio of two Poisson rates in the context of vaccine efficacy trials. ESAIM, Probability & Statistics 16 (2012), 375--398.

Examples

Run this code
x <- 3; y <- 10; S <- 100; T <- 100
rr_intervals(x, y, S, T)
brr_intervals(x, y, S, T)

Run the code above in your browser using DataLab