0
$\begingroup$

I know that the correlation function between random variables $X$ and $Y$ is defined as

$$ \rho_{X,Y}=\mathrm{corr}(X,Y)={\mathrm{cov}(X,Y) \over \sigma_X \sigma_Y} ={E[(X-\mu_X)(Y-\mu_Y)] \over \sigma_X\sigma_Y}. $$

What does happen when $\mathbf{X}$ and $\mathbf{Y}$ are random vectors?

$$ \mathbf{X} = \begin{bmatrix} X_1 \\ X_2 \\ \vdots \\ X_n \end{bmatrix}, \quad \quad \mathbf{Y} = \begin{bmatrix} Y_1 \\ Y_2 \\ \vdots \\ Y_n \end{bmatrix} $$

How is the correlation function defined in this case?

$$ \mathrm{corr}(\mathbf{X},\mathbf{Y}) \, \triangleq \, ? $$

$\endgroup$
  • 1
    $\begingroup$ Then the correlation is a matrix where the $(i,j)$th entry is the correlation between $X_i$ and $Y_j$. $\endgroup$ – Stefan Hansen Mar 31 '13 at 8:40
1
$\begingroup$

You almost answered your own question. Just put vectors with $X$ and $Y$ and transpose one of them to get a matrix: a covariance matrix. So, $$\mathrm{cov}(\mathbf{X},\mathbf{Y}) \, \triangleq \,(\vec{\mathbf{X}}-E[\vec{\mathbf{X}}]).(\vec{\mathbf{Y}}-E[\vec{\mathbf{Y}}])^{T}$$ is a matrix with entries: $\mathrm{cov}(\mathbf{X},\mathbf{Y})_{ij}=\langle(X_i-\mu_{X_i})(Y_j-\mu_{Y_j})\rangle$.

$\endgroup$
  • $\begingroup$ As far as I see, "correlation" and "covariance" are different things in single variable case. Are they the same things in multivariate case? Because, my question was about correlation, not covariance. $\endgroup$ – hkBattousai Apr 1 '13 at 4:47
  • $\begingroup$ @hkBattousai the difference is "in the mean". If you substract the mean from the vector (or scalar, that doesn't matter) then you have covariance if you don't then correlation. It is just terminology. $\mathrm{cov}(\mathbf{X},\mathbf{Y}) \, \triangleq \,(\vec{\mathbf{X}}-E[\vec{\mathbf{X}}]).{(\vec{\mathbf{Y}}-E[\vec{\mathbf{Y}}])}^{T}$ and $\mathrm{cor}(\mathbf{X},\mathbf{Y}) \, \triangleq \,\vec{\mathbf{X}}.\vec{\mathbf{Y}}^{T}$ $\endgroup$ – Caran-d'Ache Apr 1 '13 at 7:00
  • $\begingroup$ Isn't covariance defined as $\, \mathrm{cov}(\mathbf{X},\mathbf{Y}) \, \triangleq \, E\big[(\vec{\mathbf{X}}-E[\vec{\mathbf{X}}])(\vec{\mathbf{Y}}-E[\vec{\mathbf{Y}}])^{T}\big] \,$? You wrote $\, \mathrm{cov}(\mathbf{X},\mathbf{Y}) \, \triangleq \, (\vec{\mathbf{X}}-E[\vec{\mathbf{X}}])(\vec{\mathbf{Y}}-E[\vec{\mathbf{Y}}])^{T} \,$ instead. Are you sure that your definition is correct? $\endgroup$ – hkBattousai Apr 1 '13 at 11:23
  • $\begingroup$ Well, yes sure, expectation should be taken. My fault, I was inattentive and one can correct the comment only during the period of 5 minutes. :( $\endgroup$ – Caran-d'Ache Apr 1 '13 at 11:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.