It's one logical step from what's presented in the
GNU Octave Manual, but for a given arbitrary n-dimensional matrix, to find the overall minimum or maximum value within the matrix, you simply recurse the min() or max() function as many times as there are dimensions. So for a 3-dimensional matrix, recurse function calls to min or man three times like this min(min(min(X))))
Example:
size(out)
ans = 3 32 32
min(min(min(out)))
ans = -0.99914
max(max(max(out)))
ans = 1
No comments:
Post a Comment