Counting number of iterations done in a numeric array
1 回表示 (過去 30 日間)
古いコメントを表示
Hello! I'm new to Matlab and would like some help to get Matlab to count the numbers in an numeric array and then sort the 10 most frequent occurring numbers in descending order. Let's say the array consists of [24 12 10 24 8 8 24 13 13 13 13], I would like Matlab to order these like this 13 = 4 24 = 3 8 = 2 ...and so on.
Thank you! /Henrik
0 件のコメント
採用された回答
その他の回答 (1 件)
Henrik
2012 年 1 月 29 日
1 件のコメント
Walter Roberson
2012 年 1 月 30 日
You can discard everything after the 10th element, or you can simply choose to print only the first 10 elements.
参考
カテゴリ
Help Center および File Exchange で Shifting and Sorting Matrices についてさらに検索
製品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!