numpy/mean

Mean

Compute mean of array elements

numpy
math
aggregate

Command

np.mean(arr, axis)

Explanation

Returns the average of array elements.

Examples

Mean of all elements

np.mean(arr)

Row-wise mean

np.mean(arr, axis=1)