#### Definition of odds

Consider an event with probability $$p$$. The odds for this event are defined as: $$odds=\frac{p}{1-p}$$ That is, the odds indicate how many times is more probable that an event occurs that it dosen't occur. For instance, if the probability of having a cardiovascular event at 50 years is 0.3, the odds are 0.3/0.7= 0.43

The odds ratio (OR) is defined as the quotient of the odds of an event in two different siruations. For instance, if the probability of having a cardiovascular event at 50 years is 0.3, and 0.4 at 60 years, the OR (60 years vs. 50 years are: $$OR=\frac{0.4/0.6}{0.3/0.7}=1.56$$ Then, the odds of a cardiovascular disease are 1.56 times greater at 60 years vs. 50 years.

If OR>1 then the putative risk factor is directly correlated with the disease, If OR=1, then there is no association, whereas of OR<1 then the association is inverse.

In practice, supose you have a group of $$n_1$$ cases, and $$x_1$$ of them present the risk In a group of $$n_2$$ controls, we observe $$x_2$$ with the risk. Then the OR is computed as: $$OR=\frac{x_1 \times (n_2 - x_2)}{(n_1 \times x_1)\times x_2 }$$

#### Computing a CI for OR

In order to obtain a CI $$(1-\alpha)$$%, we first calculate: $$\sigma=\sqrt{\frac{1}{x_1}+\frac{1}{n_1-x_1}+\frac{1}{x_2}+\frac{1}{n_2-x_2}}$$ Then we compute: $$(a,b) \rightarrow log(OR) \pm z_{1-\alpha/2}\times \sigma$$ Finally, the desired CI for the OR will be: $$(e^a,e^b)$$

#### Example

Supose that we have 35 cases and 45 controls. The individulas at risk are 25 and 19 in each group. Then: $$x_1=25, n_1=35$$ $$x_2=19, n_2=45$$ $$\sigma=\sqrt{\frac{1}{25}+\frac{1}{10}+\frac{1}{19}+\frac{1}{26}}=0.48$$ $$(a,b) \rightarrow log((26 \times 25)/(19 \times 10)) \pm 1.96 \times 0.48 \rightarrow (0.29,2.17)$$ $$95\% CI \rightarrow (e^{0.29},e^{2.17}) \rightarrow (1.33, 8.78)$$

### Odds Ratio

In this application, you introduce the size of the cases group and the number of cases that show the hypothetic risk. The cases can correspond to a group that shows a disease condition.

The control group are people that do not present this disease. You must introduce the size and the observed control group and the number of controls that show the hypothetic risk

The odds ratio is estimated by its corresponding 95% confidence interval

### Odds ratio estimation

Odds ratio (OR) is calculated by dividing the odds of risk among the cases group by the odds in the control group. Estimate refers to the OR computed from the table

Lower and upper are the limits of the 95% confidence interval estimated from the table

### p value

Calculated as the probability of obtaing the OR value observed or a higher value if the true OR is 1