I am curious about the sign of $corr(y, \hat{y})$ with and without intercept.
I recall reading that when there is an intercept, the correlation is $\geq 0$, but in the case without intercept, the correlation can also be negative. From a geometric perspective, I don't see how this can be.
Regardless of whether there is an intercept, $\hat{y}$ is the orthogonal projection of $y$ onto the subspace spanned by the predictors. So shouldn't that orthogonal projection point in the same direction as $y$, in which case the correlation should be $\geq 0$ regardless of whether there is intercept or not?
Mathematically, I tried to prove this, and it seems to match my geometric intuition.
$$ \hat{y} = \hat{\beta}_{1} x + \hat{\beta}_0 \\ corr(y, \hat{y}) = corr(y, \hat{\beta}_{1} x + \hat{\beta}_0) \\ = corr(y, \hat{\beta}_{1} x) \\ = sgn(\hat{\beta}_{1}) corr(y, x) \\ $$ I believe $sgn(\hat{\beta}_{1})$ is the same as $sgn(corr(y, x))$, so the above quantity is always $\geq 0$. So we proved that $corr(y, \hat{y})$ is non-negative in the case with intercept; however, I believe this derivation also holds for the case without intercept, since $\hat{\beta}_0$ isn't really used in this derivation?
Edit: What I also want to add is, I know that when you remove the intercept, it's possible that the sign ($sgn(\hat{\beta}_{1})$) of the slope can flip; however, if the sign of the slop is flipped, doesn't the sign of $corr(y, x)$ also flip?