1, unsupported operand type (s) for/: ' Map ' and ' int '
Machine Learning Practical PCA Program
Traceback (most recent): " <ipython-input-29-808c65c1265e> " in <module> lowdmat,reconmat=pca.pca (datamat,1) "i:\ python\pca\pca.py" in PCA = mean (Datamat, axis=0)
Workaround:
2, Typeerror:ufunc ' isNaN ' not supported for the input types, and the inputs could not being safely coerced to any supported Types according to the casting rule ' safe '
Traceback (most recent): File"<ipython-input-17-945c872e5152>", Line 1,inch<module>Datamat=Pca.replacenanwithmean () File"I:\python\PCA\pca.py", line 59,inchReplacenanwithmean Meanval= Mean (Datmat[nonzero (~isNaN (Datmat[:,i]. A)) [0],i]) Typeerror:ufunc'isNaN' notSupported forThe input types, andThe inputs could notBe
Safely coerced to any supported types according to the casting rule"'Safe"'
Using the error statistics that appear in Python