Counting the maximum occurrence of an element in 3d matrix ?
2 ビュー (過去 30 日間)
古いコメントを表示
I have a matrix of dimensions (61x61x122) or (lat,lon,days), which has 0 and 1 values for random days.
I want to calculate the value of maximum occurrence of 1 for each grid (lat,lon).
0 件のコメント
採用された回答
madhan ravi
2019 年 8 月 30 日
sum(3dmatrix==1,[1,2])
% for older versions
sum(sum(3dmatrix==1,2),1)
4 件のコメント
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Logical についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!