1

I want to calculate correlation coefficient between the rows of the matrix X (N x k). Applying numpy.corrcoef(X) on a big matrix X is not efficient and it is slowing down my code so would like to make it faster.

Can somebody help me how can I achieve it? Vectorization? Any other function which is known that works fast with big N?

pelah
  • 11
  • 3

1 Answers1

1

It is already implemented. See https://pandas.pydata.org/pandas-docs/stable/generated/pandas.DataFrame.corr.html

m33n
  • 1,622
  • 15
  • 38