Initial odds, final odds and Bayes' factor

Let us go again to the above formulae, which we rewrite in different ways in order to get some insights on what is going on. Before the test, if no other information is available, the initial odds Infected vs Not Infected are given by
$\displaystyle \frac{P_0(\mbox{Inf})}{P_0(\mbox{NoInf})}$ $\displaystyle =$ $\displaystyle \frac{p}{1-p}\,,$  

equal to $1/9$ for our reference value of $p=0.1$. After the test has resulted in Positive the new probability of Infected is given by Eq. ([*]). The corresponding probability of Not Infected is given by a fraction that has the same denominator but $P($Pos$\,\vert\,$NoInf$)\cdot P_0($NoInf$)$ as numerator. The final odds are then given by
$\displaystyle \frac{ P(\mbox{Inf}\,\vert\,\mbox{Pos})}{ P(\mbox{NoInf}\,\vert\,\mbox{Pos})}$ $\displaystyle =$ $\displaystyle \frac{P(\mbox{Pos}\,\vert\,\mbox{Inf})}{P(\mbox{Pos}\,\vert\,\mbox{NoInf})}
\times \frac{P_0(\mbox{Inf})}{P_0(\mbox{NoInf})}\,.$ (19)

Using our numerical values, we get
$\displaystyle \frac{ P(\mbox{Inf}\,\vert\,\mbox{Pos})}{ P(\mbox{NoInf}\,\vert\,\mbox{Pos})}$ $\displaystyle =$ $\displaystyle \frac{\pi_1}{\pi_2}\times \frac{p}{1-p}$  
  $\displaystyle \approx$ $\displaystyle 8.2 \times \frac{1}{9}\,.$  

The effect of the test resulting in Positive has been to modify the initial odds by the factor

$\displaystyle BF_{ \mbox{\footnotesize Inf}\,vs\, \mbox{\footnotesize NoInf}}\,...
...=\frac{P(\mbox{Pos}\,\vert\,\mbox{Inf})}{P(\mbox{Pos}\,\vert\,\mbox{NoInf})}\,,$

known as Bayes' Factor.13In our case this factor is equal to $\pi_1/\pi_2 \approx 8.2$. This means that after a person has been tagged as Positive, the odds Infected vs Not Infected have increased by this factor. But since the initial odds were $1/9$, the final odds are just below 1, that is about 1-to-1, or 50-50.

In the same way we can define the Bayes Factor Not Infected vs Infected in the case of a negative result:

$\displaystyle BF_{ \mbox{\footnotesize NoInf}\,vs\, \mbox{\footnotesize Inf}}\,(\mbox{Neg})$ $\displaystyle =$ $\displaystyle \frac{P(\mbox{Neg}\,\vert\,\mbox{NoInf})}{P(\mbox{Neg}\,\vert\,\mbox{Inf})}
= \frac{1-\pi_2}{1-\pi_1}
= 44$  

This is the reason why, for a hypothetical proportion of infectees in the population of $10\%$, a negative result makes one practically sure to be not infected. The initial odds of 9-to-1 are multiplied by a factor 44, thus reaching 396, about 400-to-1, resulting into a probability of not being infected of 396/397, or 99.75%.