Understand the Relationship Between Pearson Correlation Coefficient and Cosine Similarity – Machine Learning Tutorial

By | December 7, 2020

Pearson Correlation Coefficient and Cosine Similarity can measure the correlation between two varialbes, both of them are in [-1, 1]. In this tutorial, we will discuss the relationship between them.

As to pearson correlation coefficient, it is defined as:

pearson correlation coefficient in sample

As to cosine similarity, it is defined as:

cosine distance equation

We can find:

Understand the Relationship between Pearson Correlation Coefficient and Cosine Similarity - Machine Learning Tutorial

It means pearson correlation coefficient is the cosine similarity between centered versions of \(x\) and \(y\).

Leave a Reply

Your email address will not be published. Required fields are marked *