Create a frequency table with the available number

1 回表示 (過去 30 日間)
fyza affandi
fyza affandi 2019 年 2 月 1 日
回答済み: madhan ravi 2019 年 2 月 1 日
I make a frequency table of an array using the below command
tabulate([1 2 4 4 3 4 7])
The result is as below
Value Count Percent
1 1 14.29%
2 1 14.29%
3 1 14.29%
4 3 42.86%
5 0 0.00%
6 0 0.00%
7 1 14.29%
How can I make a frequency table WITH ONLY available value. I just want this result
Value Count Percent
1 1 14.29%
2 1 14.29%
3 1 14.29%
4 3 42.86%
7 1 14.29%

採用された回答

madhan ravi
madhan ravi 2019 年 2 月 1 日
t=tabulate(...);
t(~all(t,2),:)=[]

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeLogical についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by