How to averaging each each row in cell array?

2 ビュー (過去 30 日間)
Tyann Hardyn
Tyann Hardyn 2022 年 6 月 29 日
コメント済み: Tyann Hardyn 2022 年 6 月 30 日
Hi, Community...
I just want to ask, how to averaging each of my cell array according to the row?
i want to average dst_allfiles{1}(1), dst_allfiles{2}(1), dst_allfiles{3}(1)
then
mean(dst_allfiles{1}(2), dst_allfiles{2}(2), dst_allfiles{3}(2))
mean(dst_allfiles{1}(3), dst_allfiles{2}(3), dst_allfiles{3}(3))
............................
How to do that? Thank you....

採用された回答

David Hill
David Hill 2022 年 6 月 30 日
d=cell2mat(dst_allfiles);
m=mean(d,2);
  3 件のコメント
David Hill
David Hill 2022 年 6 月 30 日
mean(d,1);%mean along columns
mean(d,2);%mean along rows
See mean documentation
Tyann Hardyn
Tyann Hardyn 2022 年 6 月 30 日
Thank you so much, bro. You helped me so much....

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeCreating and Concatenating Matrices についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by