Answers for "mean of array one dimensional array python"

3

np.array average row

>>> a = np.array([[1, 2], [3, 4]])
>>> np.mean(a)
2.5
>>> np.mean(a, axis=0)
array([2., 3.])
>>> np.mean(a, axis=1)
array([1.5, 3.5])
Posted by: Guest on December-01-2020

Code answers related to "mean of array one dimensional array python"

Python Answers by Framework

Browse Popular Code Answers by Language