How to reshape a matrix
조회 수: 8 (최근 30일)
이전 댓글 표시
Hello , i've got a k by l by m by n by o matrix and i want to reshape it into a vector.. Any ideas?
댓글 수: 0
채택된 답변
James Tursa
2012년 9월 13일
A = zeros(k,l,m,n,o);
B = A(:); % column vector
C = B.'; % row vector
For more general reshaping, see the reshape command.
댓글 수: 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!