I'm working with anaconda the next code to take out the correlation coefficient between two matrix. The first matrix read 16 files of matrix upper left. The sum is to get the average to compare with the result of another file
`` `python
for i in range(0,16):
i = i + 5
file = pd.read_csv(path,header=None)
file=file.fillna(0)
file = pd.DataFrame(file)
matrix = np.matrix(file)
matrix = np.flip(matrix, 1)
b = np.copy(matrix)
b = np.swapaxes(b, 1, 0)
np.fill_diagonal(b, 0)
c = matrix + b
sum = c.sum(0) / c.shape[0]
sum=pd.DataFrame(sum)
file2 = pd.read_csv(path,header=None)
file2=pd.DataFrame(file2)
file2 = file2.drop(file2.columns[48], axis=1)
` ``
the correlation coefficient between two files if sum is a matrix of (1,48) and file2 is a matrix of (16,48).