Hello everybody, my output is a structure like Run = theta: {1x10 cell} sigma:{1x10 cell} I want to compute the mean of theta and sigma. I would be grateful if you could lead howI should do that?
조회 수: 1 (최근 30일)
이전 댓글 표시
Run =
theta: {1x10 cell}
sigma: {1x10 cell}
댓글 수: 2
Thorsten
2015년 6월 30일
Please formally accept my answer, such that the question is marked as "answered" and is not considered by others anymore.
답변 (1개)
Thorsten
2015년 6월 30일
편집: Thorsten
2015년 6월 30일
mean(cell2mat(Run.theta))
mean(cell2mat(Run.sigma))
You could also rewrite your program and return a 10x2 matrix Y with the 10 theta values in the first row and the 10 sigma values in the second row, and then compute the mean of both using
mean(Y)
댓글 수: 1
Walter Roberson
2015년 6월 30일
I think you mean "with the 10 theta values in the first column and the 10 sigma values in the second column"
참고 항목
카테고리
Help Center 및 File Exchange에서 Spectral Measurements에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!