how to split a member of cell array
이전 댓글 표시
I have a cell array of 100*1 and each member has the size of 5*700. what I want to do is split each member to 5 member of 1*700. So my output will be a cell number of 500*1 (5*100) and each member has the size of 1*700. I hope that I could clarify what I want to do.
thanks a lot
댓글 수: 2
the cyclist
2018년 10월 1일
What class of object is the 5*700 contents of each cell? Is it a numeric array, another cell array, or something else?
Sara
2018년 10월 1일
채택된 답변
추가 답변 (1개)
the cyclist
2018년 10월 1일
Another version of the loop, that is a little bit more intuitive to me:
OutCell = cell(500, 1);
for nc = 1:100
for nd = 1:5
OutCell{5*(nc-1)+nd} = InCell{nc}(nd,:);
end
end
카테고리
도움말 센터 및 File Exchange에서 Matrix Indexing에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!