Okay, the information we have:
$Z$~$N(0,1)$
$Z$ is statistic independent of $X$
$Y=\begin{cases}a\left|X\right|&Z\ge 0\\ b\left|X\right|&Z<0\end{cases}$
We know that $X$ is a continuous random variable that $P\left(-1\le X\le 1\right)=1$ and $f_X\left(x\right)<\infty$ and $E[X]=\mu$ and $Var[X]=\sigma^2$
I have to find $$\hat{Y\:}_{opt}\left(X\right)=E\left[Y|X\right]$$
To be honest, I do not know how to start.
Thought maybe separating to $X\ge0$ and $X\le0$ and then do: $E\left[Y|X\right]=E\left[Y|X\ge 0\right]+E\left[Y|X<0\right]$
But I do not know if it is allowed or how to continue with it.
I don't think I have to use Law of total expectation since I will have two dependency and I don't know if it possible to solve it?
I guess the $MSE$ I can solve afterwards since it is just $MSE\left\{\hat{Y\:}_{opt}\left(X\right)\right\}=E\left[\left(Y-\hat{Y\:}_{opt}\left(X\right)\right)^2\right]$ .
But my problem is finding $\hat{Y\:}_{opt}\left(X\right)$
Any clues will be appreciated!!
You know the law of total expectation, apply it to the conditional expectation:
$$E[Y|X] = E[ E[Y|X,U]]$$ where $U=1$ if $Z \ge 0$, $U=0$ otherwise, and the outer expectation is wrt to $U$.
Now, $E[Y|X,U=1] = a |X|$ and $E[Y|X,U=0] = b |X|$ , which we can writen as
$$ E[Y|X,U] = |X| [ a U + b(1-U) ] $$
Can you go on from here?