how can i organize a column vector in a specific rows?
Ältere Kommentare anzeigen
I have a column vector of 1536 x 1, since I can order it in a row every 24 parts, I will make an example with a smaller vector.
1
two
3
4
5
6
7
8
9
10
it should stay like this.
1 2 3 4 5
6 7 8 9 10
but in the case of the original vector it would have to order in the following way.
1 to 24 in a row
25 to 48 in a row
....
1512 to 1536
any help would help a lot thank you very much
Akzeptierte Antwort
Weitere Antworten (1)
Image Analyst
am 10 Jun. 2022
Bearbeitet: Image Analyst
am 10 Jun. 2022
v = rand(1536, 1);
m = reshape(v, [], 24) % 24 columns.
v = rand(1530, 1);
m = reshape(v, [], 10) % 10 colums per row
Kategorien
Mehr zu Creating and Concatenating Matrices finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!