StatGardenREF. DESK
Calculators/Statistics/Relative risk
Statistics

Relative risk calculator

Compares event risk between an exposed and an unexposed (or treated and control) group.

What this calculator does

Relative risk works out compares event risk between an exposed and an unexposed (or treated and control) group. Enter your own figures above and the answer updates as you type: nothing is fixed in the code, so the result reflects exactly the numbers you supply.

The formula this calculator evaluates is printed under the tool and explained below, so you can check the working by hand or reuse it in a spreadsheet.

The formula

FormulaRR = (x₁/n₁) / (x₂/n₂); ARR = x₁/n₁ − x₂/n₂; NNT = 1/|ARR|

The inputs explained

FieldWhat to enter
Group 1 (exposed) sizeA number. Starts at 200.
Group 1 eventsA number. Starts at 40.
Group 2 (unexposed) sizeA number. Starts at 200.
Group 2 eventsA number. Starts at 20.

Worked examples

Every figure in the tables below is produced by this page’s own calculator at build time, so the numbers and the tool always agree. Select any row to load that scenario.

How the answer changes with group 1 (exposed) size

Every other input is held at the calculator’s starting values while group 1 (exposed) size varies. Select any row to load that scenario into the calculator.

How the answer changes with group 1 (exposed) size
Group 1 (exposed) sizeRelative riskAbsolute risk differenceNumber needed to treat/harm
1004.00030.0%4
1502.66716.7%6
2002.00010.0%10
3001.3333.33%31
4001.0000.000%N/A: no difference in risk
6000.6667-3.33%30