This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Author: [email protected] | |
# License: simplified BSD (3 clause) | |
# Note: code is based on scipy.stats.pearsonr | |
def ss(a, axis): | |
return np.sum(a * a, axis=axis) | |
def compute_corr(x, y): | |
x = np.asarray(x) | |
y = np.asarray(y) |