Pearson's correlation

Pearson's correlation is often given the variable name r and is calculated in the following way, where dxi and dyi are calculated as before:

Pearson's correlation

Since the standard deviations are constant values for the variables X and Y the equation can be simplified to the following, where σx and σy are the standard deviations of X and Y respectively:

Pearson's correlation

This is sometimes referred to as Pearson's product-moment correlation coefficient or simply just the correlation coefficient and is usually denoted by the letter r.

We have previously written functions ...

Get Clojure for Data Science now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.