I need to manipulate this matrix

23 vues (au cours des 30 derniers jours)
sermet
sermet le 8 Mai 2014
Modifié(e) : José-Luis le 8 Mai 2014
A=[10 20 30 40;50 60 70 80;90 100 110 120]
%I need to order each rows vertically like that;
B=[10;20;30;40;50;60;70;80;90;100;110;120]

Réponse acceptée

José-Luis
José-Luis le 8 Mai 2014
Modifié(e) : José-Luis le 8 Mai 2014
B = reshape(A',1,[]);
Alternatively:
B = A';
B = B(:);

Plus de réponses (0)

Catégories

En savoir plus sur Creating and Concatenating Matrices dans Help Center et File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by