How do I get the mode of a 3d-array?

3 visualizzazioni (ultimi 30 giorni)
Gülizar Kaya
Gülizar Kaya il 25 Apr 2018
Commentato: Matt J il 25 Apr 2018
Dear experts,
how do I get the mode of a 3D array with dim [51 75 55]. It can only contain numbers from 0:12 and I'm not interested in the zeros.

Risposta accettata

Matt J
Matt J il 25 Apr 2018
mode(nonzeros(yourArray)),
  2 Commenti
Matt J
Matt J il 25 Apr 2018
You're welcome, but please Accept-click the answer to certify that it addressed your question.

Accedi per commentare.

Più risposte (0)

Categorie

Scopri di più su MRI in Help Center e File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by