how can I find the smallest 3 numbers in a matrix array?
조회 수: 5 (최근 30일)
이전 댓글 표시
Hi everyone,
I have a matrix array with dimensons 1x91. I want to find smallest 3 numbers in this array, how can ı find ?
Thanks for you answers
댓글 수: 0
채택된 답변
Walter Roberson
2020년 2월 8일
mink(TheArray, 3)
댓글 수: 2
per isakson
2020년 2월 8일
편집: per isakson
2020년 2월 8일
>> m = rand(1,12);
>> [ mn, ix ] = mink(m,3)
mn =
0.035712 0.14189 0.42176
ix =
10 4 5
>> m(ix)
ans =
0.035712 0.14189 0.42176
참고 항목
카테고리
Help Center 및 File Exchange에서 Logical에 대해 자세히 알아보기
제품
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!