Create a matrix with specif size

3 次查看(过去 30 天)
Hi MATLAB community,
I have a array with the size (360x1), I would like to organize into a matrix with sizes (30 rows and 12 columns) using the data available on the array, organize sequencially. Which the function I can use for made this?
Thank you very much
Guilherme

采纳的回答

Ameer Hamza
Ameer Hamza 2020-4-23
编辑:Ameer Hamza 2020-4-23
See reshape()
B = reshape(A, 30, 12); % A is 360x1 and B is 30x12
It will organize the data column-wise, i.e., fill the first column, then second, and so on.

更多回答(0 个)

类别

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

产品


版本

R2019b

Community Treasure Hunt

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

Start Hunting!

Translated by