Correlation Plot

I am trying to look at correlation between different variables. I used MATLAB's corrplot function and got the attached results. The function's documentation doesn't provide detailed description of the plot. How do I interpret these results? What do the blue bars show? Why are they the same for both results A & B? What does the red line show? What more can I say about the two results? Apart from no correlation in A & Positive correlation in B)? my data matrix is 64 x 2: what are the values on the $y$ and $x$ axes of the plot?

  • 2
    $\begingroup$ I don't use MATLAB but a quick Google finds explanations, e.g. uk.mathworks.com/help/econ/corrplot.html Histograms appear on the principal diagonal; otherwise pairwise scatter plots are given. However, watch out as the same name appears to have been used for other functions. $\endgroup$ – Nick Cox Dec 20 '15 at 23:55
  • 1
    $\begingroup$ In addition to what Nick said (+1) : The red lines show (I quote the doc verbatim) "the slopes of the least-squares reference lines in the scatter plots are equal to the displayed correlation coefficients." What exactly don't you understand from MATLAB's doc? $\endgroup$ – usεr11852 Dec 20 '15 at 23:59
  • $\begingroup$ uk.mathworks.com/matlabcentral/fileexchange/35674-corrplot/… appears quite different. $\endgroup$ – Nick Cox Dec 21 '15 at 0:03
  • $\begingroup$ @NickCox: The later link from MathWorks FileExchange is a user-generated function. Realistically this is not what the OP uses. The screen-shots provided by the OP: 1. match very well with the screen-shots in the MATLAB docs; 2. are very different from the user-generated function publishers example screeshot. $\endgroup$ – usεr11852 Dec 21 '15 at 0:17
  • $\begingroup$ @usεr11852 Thanks; that's what I was guessing by analogy with software I know better, but I wanted someone closer to MATLAB to confirm it. $\endgroup$ – Nick Cox Dec 21 '15 at 14:35

The scatter plots shows paired variables with the least-squares regression line, a linear fit that matches the pattern of the paired variables (equal to the correlation Coefficients). The histograms of each single variable appear along the plots diagonal, this shows the range of values for the variable, revealing the underlying shape of distribution.

| cite | improve this answer | |

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.