Sampling a population

In Sec. [*] we went through the question of predicting the number of positives when we plan to test an entire sample of $n_s$ individuals, a fraction $p_s$ of which is assumed to be infected. At this point we have to take into account the last source of uncertainty we have to deal with. If we sample at random $n_s$ individuals out of the $N$ of the entire population, the sample will contain a fraction of infected $p_s$ usually different from the (`true') fraction $p$ of the population and described by $f(p_s\,\vert\,n_s,N,p)$. Once the pdf of $p_s$ has been somehow evaluated, we can get the pdf of interest, that is $f(n_P\,\vert\,n_s,N,p)$, extending Eq. ([*]) to



$\displaystyle f(n_P\,\vert\,n_s,N,p)\!\!\!$ $\displaystyle =$ $\displaystyle \int_0^1\!\!\!\int_0^1\!\!\!\!\int_0^1
\!\!f(n_P\,\vert\,n_s,p_s,...
...\pi_2)
\!\cdot\! f(p_s\,\vert\,p,n_s,N)
\!\cdot\! f(\pi_1) \!\cdot\! f(\pi_2)\,$   d$\displaystyle p_s$d$\displaystyle \pi_1$d$\displaystyle \pi_2\,.$  
      (61)



Subsections