🌐
NumPy
numpy.org › doc › stable › reference › generated › numpy.mean.html
numpy.mean — NumPy v2.5 Manual
numpy.mean(a, axis=None, dtype=None, out=None, keepdims=<no value>, *, where=<no value>)[source]# Compute the arithmetic mean along the specified axis. Returns the average of the array elements. The average is taken over the flattened array by default, otherwise over the specified axis.
🌐
Sharp Sight
sharpsight.ai › blog › numpy-mean
How to use the NumPy mean function - Sharp Sight
February 6, 2024 - By setting keepdims = True, we will cause the NumPy mean function to produce an output that keeps the dimensions of the output the same as the dimensions of the input.
🌐
NumPy
numpy.org › devdocs › reference › generated › numpy.mean.html
numpy.mean — NumPy v2.6.dev0 Manual
numpy.mean(a, axis=None, dtype=None, out=None, keepdims=<no value>, *, where=<no value>)[source]# Compute the arithmetic mean along the specified axis. Returns the average of the array elements. The average is taken over the flattened array by default, otherwise over the specified axis.
🌐
NumPy
numpy.org › doc › stable › reference › generated › numpy.ndarray.mean.html
numpy.ndarray.mean — NumPy v2.5 Manual
ndarray.mean(axis=None, dtype=None, out=None, *, keepdims=<no value>, where=<no value>)# Returns the average of the array elements along given axis. Refer to numpy.mean for full documentation. See also · numpy.mean · equivalent function ·
🌐
Interactive Chaos
interactivechaos.com › en › python › function › numpymean
numpy.mean | Interactive Chaos
January 21, 2019 - keepdims: (Optional) Boolean. If it takes the value True, the axes that are reduced are left in the result with dimensions with size 1. ... The numpy.mean function returns a ndarray.
Find elsewhere
🌐
NumPy
numpy.org › doc › 2.2 › reference › generated › numpy.mean.html
numpy.mean — NumPy v2.2 Manual
numpy.mean(a, axis=None, dtype=None, out=None, keepdims=<no value>, *, where=<no value>)[source]# Compute the arithmetic mean along the specified axis. Returns the average of the array elements. The average is taken over the flattened array by default, otherwise over the specified axis.
🌐
DataCamp
datacamp.com › doc › numpy › mean
NumPy mean()
The `mean()` function is typically used to compute the average of an entire array or along a specific axis, helping to summarize large datasets with a single representative number. It is especially useful in statistical analysis and data preprocessing. numpy.mean(a, axis=None, dtype=None, out=None, keepdims=)
🌐
NumPy
numpy.org › doc › 2.3 › reference › generated › numpy.ma.average.html
numpy.ma.average — NumPy v2.3 Manual
>>> np.ma.average(x, axis=1, keepdims=True) masked_array( data=[[0.5], [2.5], [4.5]], mask=False, fill_value=1e+20)
🌐
NumPy
numpy.org › doc › 2.2 › reference › generated › numpy.ma.average.html
numpy.ma.average — NumPy v2.2 Manual
>>> np.ma.average(x, axis=1, keepdims=True) masked_array( data=[[0.5], [2.5], [4.5]], mask=False, fill_value=1e+20)
🌐
NumPy
numpy.org › doc › stable › reference › generated › numpy.ma.average.html
numpy.ma.average — NumPy v2.5 Manual
>>> np.ma.average(x, axis=1, keepdims=True) masked_array( data=[[0.5], [2.5], [4.5]], mask=False, fill_value=1e+20)
🌐
NumPy
numpy.org › devdocs › reference › generated › numpy.ndarray.mean.html
numpy.ndarray.mean — NumPy v2.6.dev0 Manual
ndarray.mean(axis=None, dtype=None, out=None, *, keepdims=<no value>, where=<no value>)# Returns the average of the array elements along given axis. Refer to numpy.mean for full documentation. See also · numpy.mean · equivalent function ·
🌐
NumPy
numpy.org › devdocs › reference › generated › numpy.ma.average.html
numpy.ma.average — NumPy v2.6.dev0 Manual
>>> np.ma.average(x, axis=1, keepdims=True) masked_array( data=[[0.5], [2.5], [4.5]], mask=False, fill_value=1e+20)
🌐
NumPy
numpy.org › doc › 2.1 › reference › generated › numpy.ma.average.html
numpy.ma.average — NumPy v2.1 Manual
>>> np.ma.average(x, axis=1, keepdims=True) masked_array( data=[[0.5], [2.5], [4.5]], mask=False, fill_value=1e+20)