举例说明协方差矩阵的运算
均值,方差,协方差的运算公式举例说明代码演示import numpy as npa = np.mat([[10, 15, 29], [15, 46, 13], [23, 21, 30], [11, 9, 35]])a_mean = a.mean(axis = 0) # 求每列的均值a_d_mean = a - a_mean # 去均值的矩阵cov_x_y = np.dot(a_d_mean...
原创
2016-06-16 15:43:34 ·
10583 阅读 ·
5 评论