i have one cell V of order 1X3 and each cell has matrix of order 500X5 and i want to create matrix V of order 500X5 .please give me solution
조회 수: 3 (최근 30일)
이전 댓글 표시
V = 1X3 cell
V{1} = 500X5, V{2}= 500X5, V{3}= 500X5
i want one single matrix of order 500X5.
댓글 수: 1
Omer Yasin Birey
2018년 12월 28일
Hi Ghufran,
What do you mean by single matrix of order 500x5. Do you want to sum all the indexes of V?
채택된 답변
madhan ravi
2018년 12월 28일
편집: madhan ravi
2018년 12월 28일
Best way is to store them in a 3D matrix:
V{1} = rand(500,5); % an example
V{2} = rand(500,5);
V{3} = rand(500,5);
v=[V{:}];
VV=reshape(v,500,5,[]);
댓글 수: 3
madhan ravi
2018년 12월 28일
편집: madhan ravi
2018년 12월 28일
you need to explain once more what your trying to achieve , it's not clear yet , explain with a short explicit example
Omer Yasin Birey
2018년 12월 28일
편집: madhan ravi
2018년 12월 28일
You have 500x5x3 elements. But for a reason, you want to make it 500x5. I believe you cannot huddle them without doing any operation (like summation).
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Creating and Concatenating Matrices에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!