How to reshape a matrix
11 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
Hello , i've got a k by l by m by n by o matrix and i want to reshape it into a vector.. Any ideas?
0 Commenti
Risposta accettata
James Tursa
il 13 Set 2012
A = zeros(k,l,m,n,o);
B = A(:); % column vector
C = B.'; % row vector
For more general reshaping, see the reshape command.
0 Commenti
Vedere anche
Categorie
Scopri di più su Creating and Concatenating Matrices in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!