how i reshape data matrix?

1 次查看(过去 30 天)
Hello;
h have a matrix with size 66x100 how i change it's size to 1x6600
thanks

采纳的回答

José-Luis
José-Luis 2016-9-27
编辑:José-Luis 2016-9-27
bla = rand(66,100);
bla = bla(:)';
Please read the documentation on reshape

更多回答(1 个)

KSSV
KSSV 2016-9-27
编辑:KSSV 2016-9-27
A = rand(66,100) ;
A = A(:) ; % joins column by column
% if you want row by row
A = rand(66,100) ;
A = A' ;
A = A(:) ;
  2 个评论
José-Luis
José-Luis 2016-9-27
That would give column vector and not a row vector.
KSSV
KSSV 2016-9-28
Transposing it gives a column vector.

请先登录,再进行评论。

类别

Help CenterFile Exchange 中查找有关 Creating and Concatenating Matrices 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by