I would like to summarize one specific line of a large NumPy array. I know that the function array.max() will give the maximum for the entire array, and array.max(1) will give me the maximum for each of the lines as an array. However, I would like to get the maximum on a specific line (for example, line 7 or line 29). I have a large array, so getting the maximum for all rows will give me a significant time penalty.
performance python arrays numpy
robintw
source share