How to make one matrix?
이전 댓글 표시
Hi
I have 100 arrays i.e. each have one row and diffrent columns (say size is A = 1 * 167 and B = 1 * 189 and so on). I want to make one matrix in way that the first row is A, second row is B and so on... But the columns will remain different. How can I do it?
댓글 수: 4
Benjamin Thompson
2024년 1월 28일
Like this?
>> A = [1 2 3 4]
A =
1 2 3 4
>> B = [5 6 7 8]
B =
5 6 7 8
>> C = [A; B]
C =
1 2 3 4
5 6 7 8
If this is not right please explain more what output you want. Perhaps with a smaller example of 4 arrays what will the output look like?
No, like this:
A = [1 2 3 4]
B = [5 6 7 ]
C = [A; B]
Ahmed
2024년 1월 29일
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 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!
