I am trying to calculate Pearson's Correlation Coefficient using the product of the Mean Absolute Deviations (MADs) of my two lists as denominators instead of the Standard Deviations. Effectively, here's the formula I'm currently using:
$$\frac{ \sum_{i=1}^n \left(x_i - \overline{x}\right) \left(y_i - \overline{y}\right) }{ \left(\sum_{i=1}^n |x_i - \overline{x}|\right) \left(\sum_{i=1}^n |y_i - \overline{y}|\right) }$$
List 1: [1532, 1488, 1343, 928, 615]
List 2: [58, 35, 75, 41, 17]
- My Covariance is correct, it comes to: 5803.2000.
- However, my Correlation Coefficient comes to 1.0390632788677392.
As you can see, it's greater than 1, which shouldn't be the case. I'd like to know what changes should I make to my formula to get the correct Correlation Coefficient using MAD. Thank you.