필터 지우기
필터 지우기

max value of a cell array

조회 수: 5 (최근 30일)
Isma_gp
Isma_gp 2016년 9월 30일
답변: dbmn 2016년 9월 30일
Hi, I have the attached 8x7 cell, inside a structure (data.file_1.max). I would like to get the maximum value of the ones on the 8x7 cell, and do this for several "files" in the structure (data.file_2.max, data.file_3.max, data.file_4.max).
I get an error when trying to use max for cells. I tried using cell2mat first, but it's not working for some reason (maybe because there are cells without values?).
Thanks

답변 (1개)

dbmn
dbmn 2016년 9월 30일
max([ans{:, :}])
... you could use this together with structfun

카테고리

Help CenterFile Exchange에서 Whos에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by