I'm currently trying to solve the following exercise: A disease occurs at 0.1 percent of the population. A test for detecting the disease classifies 97 percent of the ill people as ill but also 2 percent of the healthy people. Let $\ell_0 \geq 0$ describe the loss if a healthy person is rated as ill and otherwise let $\ell_1 \geq 0$ describe the loss if an ill person is classified as healthy. Now one should formalise the Bayesian decision problem and find an Bayes-optimal decision rule.
I tried the following: Let $(\mathcal{X}, \mathcal{F}, (P_\vartheta)_{\vartheta \in \theta})$ be the statistical model, $\theta = \{0,1\}$, $A = \{0,1\}$ and $\ell(\vartheta,a)=\ell_0 1(\vartheta=1, a=0)+\ell_11(\vartheta=0, a=1)$, $a \in A, \vartheta \in \theta$. Furthermore let $\rho: \mathcal{X} \to A$ be a test for $H_0: \vartheta = 0$ vs. $H_1: \vartheta = 1$ and set $\pi_0=\pi(\{0\})=0.999$, $\pi_1=1-\pi_0$.
Now I'm not sure how to continue. I think $\pi$ should be the prior and $P_0(\rho(X)=1)=0.02$ and $P_1(\rho(X)=1)=0.97$. Is this right? Could you provide a tip what I should try next? I don't really know how to calculate the risk and finally how to minimize the integral in $\rho.$
Thanks!
Let $Ti$ denotes the event that test shows ill. $Ai$ denotes a person is actually ill. $Th$ denotes that test shows healthy. $Ah$ shows a person is actually healthy.
What we know from the hypothesis is $P(Ai)=0.001$, $P(Ti|Ai)=0.97$ and $P(Ti|Ah)=0.02$. What we need is $P(Ah|Ti)$ corresponding to the loss $l_0$ and $P(Ai|Th)$ corresponding to $l_1$.
Use Bayes' rule, we can compute $P(Ah|Ti)$ and $P(Ai|Th)$ from what we already knew from hypothesis.
By Bayes' theorem, $P(Ah|Ti)=\frac{P(Ti|Ah)P(Ah)}{P(Ti)}$ where $P(Ti|Ah)=0.02$, $P(Ah)=1-P(Ai)$, $P(Ti)=P(Ti|Ah)+P(Ti|Ai)$.