Fixing correlation coefficient equation