This is probably ridiculously simple but because I have to include the word 'negative' in my searches I'm constantly finding only posts and websites that discuss negative correlation which isn't what I'm stuck on.

Essentially, I have two variables and want to explore their correlation. As one is ordinal I'll be using Spearman's rank order correlation. The other variable was originally test scores (0-100) but they were transformed (I don't know the procedure involved; the data is supplied from a large dataset) to account for the fact that some test items were harder than others. The transformation created logits (don't understand this) where the scores are now ranging from -3 to +2.

What I'm not sure about is whether I can run a correlation using one variable that includes both positive and negative values?

  • $\begingroup$ The logit transformation is a means of scaling data on a $(0,1)$ interval to $(-\infty, \infty)$. It is defined as the log-odds: $\mathrm{log}(\frac{p}{1-p})$. So for example a test score of 80 would be rescaled to odds first ($\frac{.8}{1-.8} = 4$) and then the log taken, resulting an empirical logit ($1.38$). Note that a linear relationship (e.g, if you were to use Pearson's correlation) to the logit does not necessarily imply a linear relationship to the test score. $\endgroup$ – Dalton Hance Jul 26 '16 at 22:50
  • $\begingroup$ Ah ok that makes sense - I don't understand it to the level of doing it but that explanation helps! So because two people may get say 80% correct in the test, but they differed as to the difficulty of the questions they got correct, the logit helps to workout that someone getting 80% correct who got the harder questions correct (but easier ones incorrect) has more 'aptitude' (or whatever construct is being measured) than the other person who also got 80% correct but didn't get the harder ones correct. $\endgroup$ – SwingingStrawberry Jul 26 '16 at 23:26
  • $\begingroup$ No. It's a simple mathematical transformation. Two scores of 80% (which is represented as decimal 0.8) will result in the exact same empirical logit of 1.38. It's just math. There is no implied model or sense of harder or easier questions. $\endgroup$ – Dalton Hance Jul 27 '16 at 15:18
  • $\begingroup$ Thanks Dalton - I still don't fully understand but I think that's due to my own shortcomings with regards to statistical understanding; my thinking was based on the data being supplied coming with notes stating the logit adjusted the percentage scores using question difficulty and discrimination for each item. $\endgroup$ – SwingingStrawberry Jul 28 '16 at 15:44
  • $\begingroup$ Note that using logit rather than original scores will change the Pearson but not the Spearman correlation. To help understand what the transformation is doing, and in any case, never work with a correlation without looking at the corresponding scatter plot. $\endgroup$ – Nick Cox Aug 11 '16 at 16:59

Yes, you can. Neither Spearman's rank correlation nor Pearson product-moment correlation are restricted to positive data, because Spearman's just deals with how are values ordered and Pearson's deals with distance of (products of) values to the mean and those work equally fine if values are negative. You can even add an arbitrary real number to any of your variables and it won't change any correlation. Probably you don't find results about negative data and correlation because sign of data doesn't matter and nobody writes about it.

  • $\begingroup$ Thanks for the quick reply! That's great to hear as I was getting frustrated trying to search for the answer! $\endgroup$ – SwingingStrawberry Jul 26 '16 at 23:19

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.