0
$\begingroup$

I'm sort of stuck on this question and I can't find a similar problem online.

Consider the following to be given:
1.input x is 1D, output y is binary {0,1}
2.marginal probability of y is $\pi_y=P(y)$
3.the conditional distribution of $x|y$ is Gaussian normal, $\mu_y$ depends on binary y, variance $\sigma^2$ does not depend on y, so:

enter image description here

4.The probability of $P(y|x)$ is:
enter image description here
5.The LDA classifier for the case $\mu_1>\mu_0$ is:
enter image description here

Now I know that $\sigma^2=0.25$, $\pi_1=60\%$, $\pi_0=40\%$, $\mu_1=0.5$, $\mu_0=-0.5$; sample size is not known.
How can I calculate the tpr(true positive rate) in this case?

My current thought is,as reflected from title, from assumption 5, I can plug in numbers to see that the predicted label is 1 when $x>=0.25log(1.5)$ and take the normal density integral on x from $0.25log(1.5)$ to infinity; the result will be $P(\hat{y}=1)$ (subquestion: is the result $P(\hat{y}=1)$ or $P(\hat{y}=1|x)$). $P(y=1)$ is given, which is $\pi_1=60\%$.

From here, how do I continue do find the true positive rate? Thank you.

$\endgroup$

1 Answer 1

0
$\begingroup$

TPR is choosing $\hat{y}=1$ when $y$ is really $1$, i.e. formally $$P(\hat{y}=1|y=1)=P(X\geq \tau|y=1)$$

$p(x|y)$ is given here, and needs to be integrated from $\tau$ to $\infty$, where $\tau=0.25\log 1.5$. So, your approach is correct. However, since you cannot integrate the normal PDF, we'll need to convert it to standard normal and use the CDF table.

$$P(X\geq \tau|y=1)=P\left(Z\geq\frac{\tau-\mu_1}{\sigma}\right)\approx P(Z\geq -0.8)=1-\Phi(-0.8)=\Phi(0.8)\approx 0.7881$$

Note: in bullet point 3, you say $y|x$ is normal but it should be $x|y$.

$\endgroup$
2
  • $\begingroup$ yes, I will fix the typo. Thank you for your swift help! $\endgroup$
    – godric97
    Commented Mar 14, 2019 at 3:12
  • $\begingroup$ @godric97, you're welcome! If the answer is ok, can you accept it? $\endgroup$
    – gunes
    Commented Mar 14, 2019 at 20:19

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.