How can i use 'sum' for a 'cell array'?
48 ビュー (過去 30 日間)
古いコメントを表示
Hello
i have a cell array that i want to sum the coulmns ;
A={ 1x2 double , 1x2 double
1x2 double , 1x2 double
1x2 double , 1x2 double
1x2 double , 1x2 double }
0 件のコメント
採用された回答
KSSV
2019 年 5 月 7 日
A = cell(4,2) ;
for i = 1:4
for j = 1:2
A{i,j} = rand(1,2) ;
end
end
B = cellfun(@sum,A)
その他の回答 (1 件)
参考
カテゴリ
Help Center および File Exchange で Multidimensional Arrays についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!