How to put each group of cells in the same row ?
5 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Sarah A
am 11 Feb. 2019
Kommentiert: Sarah A
am 11 Feb. 2019
Hello,
Let we have a cell array A of size (1*5216), I want to put each 16 cell in the same row. So how can I do that ?
0 Kommentare
Akzeptierte Antwort
Guillaume
am 11 Feb. 2019
reshape(A, 16, [])'
reshapes your cell array in columns of 16 rows (since matlab is column major). Then transpose to have rows of 16 columns.
That's assuming you want to preserve the ordering, otherwise
reshape(A, [], 16)
which directly reshape in rows of 16 columns.
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Resizing and Reshaping Matrices finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!