Wager Mage
Photo by Polina Tankilevitch Pexels Logo Photo: Polina Tankilevitch

How to calculate odds ratio?

Odds and odds ratio The odds ratio is calculated by dividing the odds of the first group by the odds in the second group. In the case of the worked example, it is the ratio of the odds of lung cancer in smokers divided by the odds of lung cancer in non-smokers: (647/622)/(2/27)=14.04.

Where can I bet without SSN?
Where can I bet without SSN?

For example, Wild Casino, which allows you to bet without a social security number, offers a 100% deposit bonus up to $5,000. Las Atlantis and...

Read More »
What is a disadvantage of a bonus?
What is a disadvantage of a bonus?

The Disadvantages of Giving Bonuses Bonuses for employees can positively and negatively affect a firm and its employees. Employees may develop...

Read More »

Worked Example

In 1950, the Medical Research Council conducted a case-control study of smoking and lung cancer (Doll and Hill 1950). 649 male cancer patients were included (the cases), 647 of whom were reported to be smokers. 649 men without cancer were also included (controls), 622 of whom were reported to be smokers. The odds ratio of lung cancer for smokers compared with non-smokers can be calculated as (647*27)/(2*622) = 14.04, i.e., the odds of lung cancer in smokers is estimated to be 14 times the odds of lung cancer in non-smokers. We would like to know how reliable this estimate is? The 95% confidence interval for this odds ratio is between 3.33 and 59.3. The interval is rather wide because the numbers of non-smokers, particularly for lung cancer cases, are very small. Increasing the confidence level to 99% this interval would increase to between 2.11 and 93.25. Doll and Hill 1950 is a famous study from the literature and is described in further detail in the following reference book (pp240-243). Martin Bland, An Introduction to Medical Statistics Third Edition, Oxford University Press (2000).

Formula

This calculator uses the following formulae to calculate the odds ratio (or) and its confidence interval (ci). or = a*d / b*c, where:

a is the number of times both A and B are present,

b is the number of times A is present, but B is absent, c is the number of times A is absent, but B is present, and

d is the number of times both A and B are negative.

To calculate the confidence interval, we use the log odds ratio, log(or) = log(a*d/b*c), and calculate its standard error:

se(log(or)) = √1/a + 1/b + 1/c +1/d

The confidence interval, ci, is calculated as:

ci = exp(log(or) ± Zα/2­*√1/a + 1/b + 1/c + 1/d),

where Zα/2 is the critical value of the Normal distribution at α/2 (e.g. for a confidence level of 95%, α is 0.05 and the critical value is 1.96). Note: The logarithms included in the formulae above are natural logarithms, i.e., log base e, sometimes denoted ln().

Discussion

When the prevalence of the outcome is low, the odds ratio can be used to estimate the relative risk in a case-control study. This is useful as the calculation of relative risk depends on being able to estimate the risks. In a prospective study we can do this as we know how many of the risk group develop the outcome. However, this cannot be done if we start with the outcome and try to work back to the risk factor, as in a case-control study. Calculating a confidence interval provides you with an indication of how reliable your odds ratio is (the wider the interval, the greater the uncertainty associated with your estimate). By changing the inputs (the contingency table and confidence level) in the Alternative Scenarios you can see how each input is related to the confidence interval. The larger your sample size, the more certain you can be that the estimates reflect the population, so the narrower the confidence interval. However, the relationship is not linear, e.g., doubling the sample size does not halve the confidence interval. Choosing a sample size is an important aspect when designing your study or survey. For some further information, see our blog post on The Importance and Effect of Sample Size.

Definitions

What is 2 3 as a number?
What is 2 3 as a number?

2/3, when converted to decimals, will be equal to 0.66 which is when rounded off to the nearest whole number will be equal to 1 because the value...

Read More »
How do you predict sequence numbers?
How do you predict sequence numbers?

First, find the common difference for the sequence. Subtract the first term from the second term. Subtract the second term from the third term. To...

Read More »

Odds and odds ratio

The odds of an event occurring is calculated as the ratio of the probability of a property being present compared to the probability of it being absent; this is simply the number of times that the property is absent divided by the number of times it is absent. In the worked example, the odds of lung cancer for smokers is calculated as 647/622=1.04, whilst the odds of lung cancer for non-smokers is 2/27=0.07. The odds ratio is calculated by dividing the odds of the first group by the odds in the second group. In the case of the worked example, it is the ratio of the odds of lung cancer in smokers divided by the odds of lung cancer in non-smokers: (647/622)/(2/27)=14.04. If the odds ratio is greater than 1, then being a smoker is considered to be associated with having lung cancer since smoking raises the odds of having lung cancer.

Contingency table

The contingency table summarises the outcomes of each individual sampled in terms of whether Properties A and B are absent or present. It represents the joint frequency distribution of the two properties.

Confidence level

The confidence level is the probability that the confidence interval contains the true odds ratio. If the study was repeated and the range calculated each time, you would expect the true value to lie within these ranges on 95% of occasions. The higher the confidence level the more certain you can be that the interval contains the true odds ratio.

How far has an 8 seed gone?
How far has an 8 seed gone?

How Far Does Each Seed Advance? Seed R64, R32, S16, E8, F4, NF Standard Deviation for the Number of Wins 8 72, 15, 9, 6, 4, 1 1.09 9 76, 7, 4, 1,...

Read More »
Is it better to bet each way or place?
Is it better to bet each way or place?

Deciding between a place wager and an each way bet very much depends on whether you think the selection has any real chance of winning. To some...

Read More »
How can I know if someone saved my number on Telegram?
How can I know if someone saved my number on Telegram?

Follow these steps: Launch Telegram on your device (computer, tablet, smartphone, it doesn't matter). Tap the three lines in the top left corner of...

Read More »
Is VPN safer than WIFI?
Is VPN safer than WIFI?

When you use a VPN, your internet traffic gets encrypted, so no one can intercept it via public Wi-Fi. Even though you're not using a secure Wi-Fi...

Read More »