GeeksforGeeks
geeksforgeeks.org › python › numpy-maximum-in-python
numpy.maximum() in Python - GeeksforGeeks
December 19, 2025 - Example: This example shows how numpy.maximum() compares two numbers and returns the larger one. Python · import numpy as np a = 10 b = 21 print(np.maximum(a, b)) Output · 21 · numpy.maximum(arr1, arr2, /, out=None, *, where=True, ...
NumPy
numpy.org › doc › 2.2 › reference › generated › numpy.max.html
numpy.max — NumPy v2.2 Manual
Notice that the initial value is used as one of the elements for which the maximum is determined, unlike for the default argument Python’s max function, which is only used for empty iterables.
03:39
NumPy np.max() Tutorial: Find Maximum Values in Arrays | Python ...
02:25
Python Numpy Max Function - YouTube
Finding Maximum and Minimum in Numpy Array
00:53
How To Find Min/Max Value In Numpy Array | Python Tutorial - YouTube
04:16
Numpy - Find the index of the min/max value | argmin argmax tutorial ...
11:33
Python Numpy max min where - YouTube
Programiz
programiz.com › python-programming › numpy › methods › maximum
NumPy maximum() (With Examples)
Here, maximum() compares the corresponding elements of array1 and array2 and returns a new array result with the maximum value at each position. import numpy as np array1 = np.array([1, 3, 5, 7, 9]) array2 = np.array([2, 4, 6, 8, 10]) # create an empty array with the same shape as array1 output ...
NumPy
numpy.org › doc › stable › reference › generated › numpy.maximum.html
numpy.maximum — NumPy v2.5 Manual
The maximum value of an array along a given axis, propagates NaNs.
DataCamp
datacamp.com › doc › numpy › max
NumPy max()
import numpy as np matrix = np.array([[1, 2, 3], [4, 5, 6], [7, 8, 9]]) max_in_columns = np.max(matrix, axis=0) print(max_in_columns) Here, `np.max(matrix, axis=0)` computes the maximum values along each column, resulting in `[7, 8, 9]`. max_in_rows = np.max(matrix, axis=1) print(max_in_rows) In this additional example, `np.max(matrix, axis=1)` computes the maximum values along each row, resulting in `[3, 6, 9]`.
Codecademy
codecademy.com › docs › python:numpy › built-in functions › .max()
Python:NumPy | Built-in Functions | .max() | Codecademy
July 2, 2025 - If axis is specified, returns an array with maximum values along the specified axis. Note: If any element in the input array is NaN, the function will return NaN. To ignore NaN values, use np.nanmax() instead. This example demonstrates finding the maximum value in a one-dimensional array:
Programiz
programiz.com › python-programming › numpy › methods › max
NumPy max()
If axis = 1, the maximum of the largest element in each row is returned. import numpy as np array = np.array([[10, 17, 25], [15, 11, 22]])
NumPy
numpy.org › doc › 2.1 › reference › generated › numpy.maximum.html
numpy.maximum — NumPy v2.1 Manual
The maximum value of an array along a given axis, propagates NaNs.
Python Examples
pythonexamples.org › python-numpy-maximum-value-of-array
Python Program - Maximum Value of Numpy Array - numpy.max()
Python Program to get the maximum value of Numpy Array - To get the maximum value of a Numpy Array, use numpy function numpy.max(). Example programs contain a numpy array and finding the element with maximum or largest value.
NumPy
numpy.org › devdocs › reference › generated › numpy.max.html
numpy.max — NumPy v2.6.dev0 Manual
Maximum of a. If axis is None, the result is a scalar value. If axis is an int, the result is an array of dimension a.ndim - 1.
Call: +917738666252
Address: Unit no. 202, Jay Antariksh Bldg, Makwana Road, Marol, Andheri (East),, 400059, Mumbai
NumPy
numpy.org › doc › stable › reference › generated › numpy.max.html
numpy.max — NumPy v2.5 Manual
Notice that the initial value is used as one of the elements for which the maximum is determined, unlike for the default argument Python’s max function, which is only used for empty iterables.
Tutorial Gateway
tutorialgateway.org › python-numpy-max
Python numpy max
September 18, 2022 - In this example, np.max(a, axis = 1, out = x) will save the maximum of each row result in x array. import numpy as np a = np.random.randint(10, 80, size = (5, 4)) print(a) x = np.arange(5) b = np.max(a, axis = 1) print(b) np.max(a, axis = 1, out = x) print('x = ', x) [[47 14 73 75] [35 60 64 ...
NumPy
numpy.org › devdocs › reference › generated › numpy.maximum.html
numpy.maximum — NumPy v2.6.dev0 Manual
The maximum value of an array along a given axis, propagates NaNs.
NumPy
numpy.org › doc › 2.0 › reference › generated › numpy.maximum.html
numpy.maximum — NumPy v2.0 Manual
The maximum value of an array along a given axis, propagates NaNs.
NumPy
numpy.org › doc › 2.1 › reference › generated › numpy.max.html
numpy.max — NumPy v2.1 Manual
Maximum of a. If axis is None, the result is a scalar value. If axis is an int, the result is an array of dimension a.ndim - 1.
NumPy
numpy.org › doc › 2.2 › reference › generated › numpy.maximum.html
numpy.maximum — NumPy v2.2 Manual
The maximum value of an array along a given axis, propagates NaNs.