Transform array to matrix
조회 수: 9 (최근 30일)
이전 댓글 표시
Hi, I want to transform the array A=[1 2 3 4 5] to this matrix A= [1 2; 2 3; 3 4; 4 5] Is it possible? Thank you very much
댓글 수: 0
채택된 답변
James Tursa
2018년 3월 5일
Hint: Look at combining the results of A(1:end-1) and A(2:end) into your resulting matrix.
댓글 수: 0
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Resizing and Reshaping Matrices에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!