Correlations - Pearson and Spearman I know that Pearson correlation is sensitive to outliers, unlike Spearman correlation.  I am trying to generate data (let's say with at least 30 points) that will maximize the difference between these two methods. I was trying to generate some points in an ascending linear direction, and then one outlier point in the opposite direction. It indeed showed a big difference in the coefficients, but not as much as I wanted. Any ideas?


I know that Pearson correlation is sensitive to outliers, unlike Spearman correlation.

There is a more striking difference between the two: Pearson assumes a linear relationship between the data, whereas Spearman checks whether it is simply monotonuous (see the image below, taken from Wikipedia). Generating data via a non-linear process is thus a way to show that these are not equivalent.

A Spearman correlation of 1 results when the two variables being compared are monotonically related, even if their relationship is not linear. This means that all data points with greater x values than that of a given data point will have greater y values as well. In contrast, this does not give a perfect Pearson correlation.


