1
$\begingroup$

Could someone explain to me why the following equation holds? It is related to the law of total probability , but I don't get it. I'm confused because it's two random variables on the right side and therefore it should also be a joint distribution, right ?

$$\begin{align} \int \limits_0^\infty f_X(x) \ \mathbb{P}(Y<x) \ dx &= \mathbb{P}(Y<X) \end{align}$$

I understand that $$\begin{align} \mathbb{P}(X \in A, Y \in B) = \int_B f_Y(y) \int_A f_X(x|Y = y) \ dx \ dy . \end{align}$$

But how do I put this together?

$\endgroup$

1 Answer 1

0
$\begingroup$

Consider the continuous random variables $W$ and $V$ and their joint distribution $p(w,v)$. By the law of total probability, note that $$ p(w) = \int p(w,v) \ \text{d}v $$ and by Bayes' rule \begin{align} p(w) &= \int p(w,v) \ \text{d}v \\ &= \int p(w \mid v) \cdot p(v) \ \text{d}v \end{align} Going back to your random variables, note that $$ p(Y < X) = \int p(Y < X \mid x) \cdot p(x) \ \text{d}x $$ Since $X$ is given in $p(Y < X \mid x)$, then we can let $$ p(Y < X \mid x) = p(Y < x) $$ such that $$ p(Y < X) = \int p(Y < x) \cdot p(x) \ \text{d}x $$ Another way to see this is to let $$ Z = \begin{cases} 1 \quad \text{if} \quad Y < X \\ 0 \quad \text{otherwise} \end{cases} $$ We are therefore interested in $p(Z = 1)$. By the law of total probability and Bayes' rule, $$ p(Z = 1) = \int p(Z = 1 \mid x) \cdot p(x) \ \text{d}x $$

$\endgroup$
2
  • $\begingroup$ Hi, thank you for your reply! Could you be more specific with the Integral limits? Do you mean integrating x out? Why is it then still a random variable... For example, in your first equations (law of total prob.), we are integrating v out, therefore we get the marginal. But dont hold anymore, by consindering Y < X ? $\endgroup$
    – Camilo
    Commented Nov 28, 2021 at 19:00
  • $\begingroup$ Yes we are integrating $v$ out. Not sure what you are asking about... $\endgroup$
    – mhdadk
    Commented Nov 28, 2021 at 19:11

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.