How to know the smallest number after 0
2 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
mohd akmal masud
am 29 Dez. 2021
Kommentiert: Voss
am 29 Dez. 2021
Hi all, I have set images 3D (256x256x90 uint16), let say P. Anyone know how to know the smallest number after 0?
>> min(min(min(P)))
ans =
uint16
0
>> max(max(max(P)))
ans =
uint16
1387
1 Kommentar
Akzeptierte Antwort
Weitere Antworten (1)
Chunru
am 29 Dez. 2021
P = randi([0 65535], [5 5 10], 'uint16'); % smaller size for demonstration
P1 = P(:);
min(P1(P1>0))
Siehe auch
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!