Odds ratio vs relative risk app
(Click image to open app)
This app demonstrates how odds ratio and relative risk relate to one another, and the vital role of baseline risk in connecting the two.
Odds ratios are commonly misinterpreted as though they are relative risks, but these statistics are not interchangable and their values can differ dramatically. Relative risk has a more intuitive interpretation ("how much more likely an outcome is under one condition than another), but there are situations in which odds ratio can be estimated while relative risk cannot , such as case-control studies and logistic regression. And, importantly, it is not possible to convert one of these statistics to the other unless a baseline risk is assumed.
The purpose of this app is to show how odds ratio and relative risk are related to one another, given an assumed baseline probability. The user can set an odds ratio, then change baseline probability and see the implied relative risk. The app shows this a few different ways:
The relevent formulas for relative risk and odds ratio are presented at the top of the app; user can see these values change as they adjust the inputs.
The bottom right plot shows relative risk as a function of baseline risk, given odds ratio. The user can see which values of baseline risk results in odds ratio and relative risk being similar, and which result in them differing dramatically.
The probabilities of an outcome being present or absent, given exposure or non-exposure to a risk factor, are represented as lines on the bottom left plot. The purple lines represent probabilities of the outcome being present; the green lines represent probabilities of the outcome being absent. These same lines are displayed at the top of the app to show where they fit in to the formulas for relative risk and odds ratio.
Relative risk and odds ratio can be displayed as ratios of areas on the plot. The buttons on the left to rectangles representing probabilities, odds, relative risk, and odds ratio.