Why is $Y$ and linear function of $X$ if the correlation equals $+1$ or $-1$?

494 Views Asked by At

Just looking for a proof of $\operatorname{Cor}(X,Y) = \begin{cases} +1 & \text{if } a>0, \\ -1 & \text{if } a<0, \end{cases}$ where $X$ and $Y$ are random variables such that $Y=aX+b$ and $a$ and $b$ are constants.

1

There are 1 best solutions below

0
On

By definition $\operatorname{Corr}(X,Y)=\frac{\operatorname{Cov}(X,Y)}{\sigma_X \sigma_Y}$. When $\operatorname{Var}(Y)=\operatorname{Var}(aX+b)=a^2\operatorname{Var}(X)$, hence $\sigma_X \sigma_Y =|a| \sigma_X^2$.

In addition, $\operatorname{Cov}(X,Y) = \operatorname{Cov}(X,aX+b) = \operatorname{Cov}(X,aX) = a\operatorname{Cov}(X,X)=a\operatorname{Var} (X)=a\sigma_X^2$, so, $$ \operatorname{Corr}(X,Y)=\frac{|a|}{a},\quad a\neq0 $$