I have an n-dimensional matrix Q. I can find the max values through the last dimension by:
m = max(Q,[],n).
However, I do not know how to find the max values through the last "slice". I need something "like"
m = max(Q,[],n-1,n).
For example, if I have
A(:,:,1) = [1 2 3 ; 4 50 6]
A(:,:,2) = [9 8 7 ; 10 12 1]
I would like to have m = [9 50]
.
Can you help me with this?