2017-02-21 numpyの配列の要素を四捨五入する numpy python numpyの配列の要素を四捨五入する import numpy as np a = np.array([0.01, 2.0]) a = np.array(a) # => array([0., 2.])