# Probabilities of conditional expectation values in uniform distribution

Let's consider a continuous random variable $X$ as follows:

$f_X(x)=\left\{ \begin{array}{ll}\frac{1}{2}, &\mbox{if} \ x\in[0,1] \\ \frac{1}{4}, &\mbox{if}\ x\in(1,3]\end{array}\right.$

Let $Y$ a new random variable defined as:

$Y=\left\{\begin{array}{ll}1, & \mbox{if}\ x<1 \\ 2, & \mbox{if}\ x\geq 1 \\ \end{array} \right.$

I was given that the conditional expectation $E[X|Y]$ takes the values $\frac{1}{2}$ and $2$ with the same probability $\frac{1}{2}$ and I am wondering why that is true.

So, I constructed the conditional PDFs:

For y=1: $f_{X|Y}(x|1)=\left\{\begin{array}{ll}1, & \mbox{if}\ x\in[0,1]\\ 0, & \mbox{otherwise} \\ \end{array} \right.$

For y=2: $f_{X|Y}(x|2)=\left\{\begin{array}{ll}\frac{1}{2}, &\mbox{if}\ x\in[1,3]\\ 0, & \mbox{otherwise} \\ \end{array} \right.$

from which we understand that both conditional PDFs are uniformly distributed between a and b (in the general case) so we know that the expectation of such a distribution is $\frac{a+b}{2}$. In our case $E[X|Y=1]=\frac{1}{2}$ and $E[X|Y=2]=2$

But, why are those cases of equal probability $\frac{1}{2}$? I mean, isn't $Y=2$ a more probable case?

P(X <= 1) = 1/2