Given a random variable $X$ and a sub sigma algebra $N$ of its sampling space, it is often said that $E(\dot \, \mid N)$ is an orthogonal projection, since $X-E(X\mid N)$ and $E( X\mid N)$ are uncorrelated.
I understand that to be $X-E(X\mid N)$ is orthogonal to some subspace of random variables which include $E(X\mid N)$. I wonder how to determine the subspace of random variables from $N$?
Here do we require $X$ to be $L^2$ or $L^1$?
Thanks!