Skip to main content
MedCalc
Mail a PDF copy of this page to:
(Your email address will not be added to a mailing list)  # Relative risk, Risk difference and Odds ratio

When the data to be analyzed consist of counts in a cross-classification of two groups (or conditions) and two outcomes, the data can be represented in a fourfold table as follows:

Group 1Group 2Total
Number with positive outcomeaca+c
Number with negative outcomebdb+d
Totala+bc+da+b+c+d

Several statistics can be calculated such as relative risk and risk difference, relevant in prospective studies, and odds ratio, relevant in retrospective case controls studies.

## Relative risk

The relative risk (RR), its standard error and 95% confidence interval are calculated according to Altman, 1991.

The relative risk or risk ratio is given by $$RR = \frac {a/(a+b) } { c/(c+d) }$$

with the standard error of the log relative risk being $$\operatorname{SE} \left \{ \operatorname{ln}\left(RR\right) \right \} = \sqrt { \frac {1}{a} + \frac {1}{c} - \frac {1}{a+b} - \frac {1}{c+d} }$$

and 95% confidence interval $$\operatorname{95\%\text{ } CI} = \operatorname{exp} \Big( \text{ } \operatorname{ln}\left(RR\right) - 1.96 \times \operatorname{SE} \left \{ \operatorname{ln}\left(RR\right) \right \} \text{ } \Big) \quad \text{ to }\quad \operatorname{exp} \Big(\text{ } \operatorname{ln}\left(RR\right) + 1.96 \times \operatorname{SE} \left \{ \operatorname{ln}\left(RR\right) \right \} \text{ }\Big)$$

## Risk difference

The risk difference (RD) and its 95% confidence interval are calculated according to Newcombe & Altman (2000) $$RD = \frac {a} {a+b} - \frac {c} {c+d}$$

The recommended method for the calculation of the risk difference, which is a difference between proportions, requires the calculation of the confidence intervals of the two proportions separately. MedCalc calculates exact binomial confidence intervals for proportions (Armitage et al., 2002). With l1 to u1 being the 95% CI of the first proportion p1 and l2 to u2 being the 95% CI of the second proportion p2, the 95% confidence interval for the difference is given by $$\operatorname{95\%\text{ } CI} = RD - \sqrt { (p_1-l_1)^2 + (u_2-p_2)^2 } \quad \text{ to }\quad RD + \sqrt { (p_2-l_2)^2 + (u_1-p_1)^2}$$

In the context of meta-analysis, the standard error and 95% confidence interval are calculated according to Deeks & Higgins (2010), where the standard error is defined as $$\operatorname{SE} \left \{ RD \right \} = \sqrt { \frac {a \times b}{ \left ( a+b \right )^3} + \frac {c\times d}{\left (c+d\right )^3} }$$

and 95% confidence interval $$\operatorname{95\%\text{ } CI} = RD - 1.96 \times \operatorname{SE} \left \{ RD \right \} \quad \text{ to }\quad RD + 1.96 \times \operatorname{SE} \left \{ RD \right \}$$

## Odds ratio

The odds ratio (OR), its standard error and 95% confidence interval are calculated according to Altman, 1991.

The odds ratio is given by \begin{align} OR & = \frac {a/b} {c/d} \\ & = \frac {a \times d } { b \times c} \end{align}

with the standard error of the log odds ratio being $$\operatorname{SE} \left \{ \operatorname{ln}\left(OR\right) \right \} = \sqrt { \frac {1}{a} + \frac {1}{b} + \frac {1}{c} + \frac {1}{d} }$$

and 95% confidence interval $$\operatorname{95\%\text{ } CI} = \operatorname{exp} \Big( \text{ } \operatorname{ln}\left(OR\right) - 1.96 \times \operatorname{SE} \left \{ \operatorname{ln}\left(OR\right) \right \} \text{ }\Big) \quad \text{ to }\quad \operatorname{exp} \Big(\text{ } \operatorname{ln}\left(OR\right) + 1.96 \times \operatorname{SE} \left \{ \operatorname{ln}\left(OR\right) \right \} \text{ }\Big)$$

## Notes

Where zeros cause problems with computation of effects or standard errors, 0.5 is added to all cells (a, b, c, d) (Pagano & Gauvreau, 2000; Deeks & Higgins, 2010).

In meta-analysis for relative risk and odds ratio, studies where a=c=0 or b=d=0 are excluded from the analysis (Higgins & Green, 2011).

## Statistics with Confidence: Confidence Intervals and Statistical GuidelinesAltman DG, Machin D, Bryant TN, Gardner MJ (Eds)

Buy from Amazon US - CA - UK - DE - FR - ES - IT

This introduction to confidence intervals has been updated and expanded to include methods for using confidence intervals, with illustrative worked examples and extensive guidelines and checklists to help the novice. There are six new chapters on areas such as diagnostic studies and meta-analyses.