zepid.calc.utils.incidence_rate_ci(events, time, alpha=0.05)

Calculate two-sided incidence rate confidence intervals. Only Wald-type confidence intervals are currently implemented.

Incidence rate is calculated from

\[I = \frac{a}{t}\]

Incidence rate standard error is

\[SE = \left(\frac{a}{t^2}\right)^\frac{1}{2})\]
  • events (integer, float) – Number of events/outcomes that occurred
  • time (integer, float) – Total person-time contributed in this group
  • alpha (float, optional) – Alpha level. Default is 0.05

Tuple containing incidence rate, lower CL, upper CL, SE

Return type:



Estimate the incidence rate, standard error, and confidence intervals

>>> from zepid.calc import incidence_rate_ci
>>> i = incidence_rate_ci(56, 503)

Extracting the estimated incidence rate

>>> i.point_estimate

Extracting the lower and upper confidence intervals, respectively

>>> i.lower_bound
>>> i.upper_bound

Extracting the standard error

>>> i.standard_error