I am searching for the formula to calculate the correlation coefficient in case of multiple linear regression. Please help me out!


I have 2 independent variables: $X1$ and $X2$ and 1 dependent variable $Y$. I want to study whether there is correlation between the 3 parameters. The model is

$$ Y = aX1 + bX2 + c $$

I was able to calculate $a$, $b$, and $c$. Now I need to 'analyze' whether there is a correlation. In case of linear regression $x$ and $y$, the formula is:

$$ r = \frac{cov(x,y)}{ \sqrt{var(x)var(y)} } $$

What is the formula in case of $x1$, $x2$, and $y$.

Is it called multiple correlation?

  • 1
    $\begingroup$ What do you mean by "the" correlation coefficient, given that (by definition) there is more than one regressor variable in any multiple regression? $\endgroup$
    – whuber
    Oct 8, 2015 at 14:52
  • $\begingroup$ @whuber I gave more details. $\endgroup$
    – nath234
    Oct 8, 2015 at 14:59
  • $\begingroup$ Same question: what do you mean by "a correlation"? Perhaps this would be a good time to do a little looking around this site or a textbook so you can become familiar with what multiple regression is and what kind of information one obtains from it. $\endgroup$
    – whuber
    Oct 8, 2015 at 15:03
  • $\begingroup$ @whuber, I have read this link stat.yale.edu/Courses/1997-98/101/linmult.htm. They seem to calculate Rsquared. But the formula is not there. Can you please give me hints or direct me? $\endgroup$
    – nath234
    Oct 8, 2015 at 15:05
  • $\begingroup$ @whuber, is multiple correlation the term word I am looking for? $\endgroup$
    – nath234
    Oct 8, 2015 at 15:28

1 Answer 1


Multiple correlation IS what you are looking for. It is a measure of how well the dependent variable can be predicted by a set of independent variables. The symbol is $R$ and it should be $R>0$.

Assuming your independent variables are $x$ and $y$. The dependent variables is $z$, then the multiple correlation coefficient is given by

$$ R_{z,xy} = \sqrt{ \frac{r_{xz}^2 + r_{yz}^2 - 2r_{xz}r_{yz}r_{xy} }{ 1-r_{xy}^2 } }$$

where $r_{xz}$, $r_{yz}$, and $r_{xy}$ are defined as the correlation coefficient between 2 variables. The formula to each is the one you stated above.

  • $\begingroup$ What if I want to study the effect of $x1$ on $y$ (without taking into account $x2$) and then study the effect of $x2$ on $y$ (without taking into account the effect of $x1$). Is it possible? $\endgroup$
    – nath234
    Oct 8, 2015 at 17:40
  • $\begingroup$ Those two studies are called simple regression. There are many examples of its theory, output, and interpretation on this site. $\endgroup$
    – whuber
    Oct 9, 2015 at 14:58
  • $\begingroup$ @whuber, the OP might also be interested in the partial correlation and/or the semi-partial correlation. In his case, this approach or the simple regression approach should give the same results since he's dealing with only 2 independent variables. Hence, holding one as a constant reduces to the simple regression form. Please correct me if I am wrong. $\endgroup$
    – aloha
    Oct 12, 2015 at 9:20
  • $\begingroup$ The simple (univariate) regression coefficients will differ from the multivariate coefficients when there are two or more regressors that are not orthogonal. The simple correlation coefficients will also differ from the partial correlation coefficients in those cases. $\endgroup$
    – whuber
    Oct 12, 2015 at 16:28
  • $\begingroup$ @whuber, then which one do you suggest I use? The simple correlation coefficient or the partial correlation coefficient? $\endgroup$
    – nath234
    Oct 19, 2015 at 9:41

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.