ci.ratio.poisson2: Confidence interval for a ratio of Poisson rates in a 2-group...

View source: R/statpsych3.R

ci.ratio.poisson2R Documentation

Confidence interval for a ratio of Poisson rates in a 2-group design

Description

Computes a confidence interval for a ratio of population Poisson rates in a 2-group design. The confidence interval is based on the binomial method with an Agresti-Coull confidence interval. This function requires the number of occurences of a specific event (f) that were observed over a specific period of time (t) within each group.

Usage

ci.ratio.poisson2(alpha, f1, f2, t1, t2)

Arguments

alpha

alpha value for 1-alpha confidence

f1

number of event occurences for group 1

f2

number of event occurences for group 2

t1

time period for group 1

t2

time period for group 2

Details

The time periods do not need to be integers and can be expressed in any unit of time such as seconds, hours, or months. The occurances are assumed to be independent of one another and the unknown occurance rate is assumed to be constant over time within each group condition.

Value

Returns a 1-row matrix. The columns are:

  • Estimate - estimated ratio of Poisson rates

  • LL - lower limit of the confidence interval

  • UL - upper limit of the confidence interval

References

\insertRef

Price2000statpsych

Examples

ci.ratio.poisson2(.05, 19, 5, 30, 40.5)

# Should return:
# Estimate       LL       UL
#     5.13 1.939576 13.71481
 


statpsych documentation built on Sept. 11, 2024, 7:42 p.m.