I have a 10*1 cell array named Data.mat, that each row of it contains a 30*30 matrix. How to calculate the mean of this cell array and obtain a 30*30 matrix? Thanks in advance for your kind help. Regards, Mahesh.

 채택된 답변

Walter Roberson
Walter Roberson 2024년 2월 5일

2 개 추천

mean(cat(3, TheCellArray{:}),3)

댓글 수: 1

Anampally  Mahesh
Anampally Mahesh 2024년 2월 5일
Thank you so much, Walter.
It works very nicely :)

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 Resizing and Reshaping Matrices에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by