python :invalid value encountered in true_divide。(除法遇到无效值)
假设有这样一个需求(不是假设,是真的):给出历年的预算费用,求增长率。为方便后续计算,用matrix矩阵实现。#历史数据his=matrix([[30000.,20000.,10000.,1000.],[0.,0.,0.,9000.],[0.,0.,10000.,0.],[0.,10000.,10000.,1000.],[0.,0.,0.,9000.]])#假装是现在的数据cur=his*1.24