Too bad there's no way to return the alternate return values as function result or could manage in one line/anonymous function. MATLAB syntax here requires the temporary variable.
NB: max(max()) uses default behavior of max (and most other MATLAB functions) to operate by column by default -- hence the inside max() returns a row vector of column max'es; the second then returns the location of the max in that vector--the desired column of the overall max in the array.
One could find the overall maximum location via
but one then would need to convert that linear location back to row, column by ind2sub
requiring yet another temporary since the column is the second output form ind2sub