필터 지우기
필터 지우기

Info

이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.

I have a matrix of dimension a=[993,1], I need a matrix b=[331,3] such that every 3 columns of the a forms a row of b

조회 수: 1 (최근 30일)
the problem is like a=[1;2;3;4;5;6;7;8;9;10;11;12;13;14;15;16;17;18] and I need b of the following form b=[1 2 3;4 5 6; 7 8 9; 10 11 12; 13 14 15; 16 17 18]

답변 (1개)

Mischa Kim
Mischa Kim 2014년 6월 3일
Chris, use
b = reshape(a',3,[])'

이 질문은 마감되었습니다.

태그

Community Treasure Hunt

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

Start Hunting!

Translated by