multi-dimensional array, minimum, coordinate

1 view (last 30 days)
Hello, I have to find minimum element of multi-dimensional array and its coordinate
I have this, error=criteria(k,code,i);
thanks

Accepted Answer

Azzi Abdelmalek
Azzi Abdelmalek on 26 Apr 2014
a=rand(3,4,5);
[min_v,idx]=min(a(:))
[ii,jj,kk]=ind2sub(size(a),idx)

More Answers (0)

Categories

Find more on Matrices and Arrays in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!