How to rearrange data by cutting rows and placing in new columns or using cell array?

1 次查看(过去 30 天)
I have a folder of files that are all lengths of multiples of 128 (one may be 768 and another may be 1024) with 4 columns of data points at each point. I need to reaarrange them so that each set of 128x4 is placed side by side in columns. So beginning with data with dimensions of 768x4 and ending with 128x24. Another alternative that would also work for me would be to place each extracted 128x4 set into a cell array for each set of data.
I am not sure the best way to do this and I'm sure it is easier than I am making it, but I have not succeed when trying to use mat2cell or cbind/rbind.

采纳的回答

Fangjun Jiang
Fangjun Jiang 2021-1-19
reshape()?
  5 个评论
Undergrad
Undergrad 2021-1-19
The ordering on the datapoints in each 128x4 set must keep the same orientation. The issue is that in data collection, these sets have been placed in consecutive rows (making the size of the whole array something like 1024x4). I need to move each of these 128x4 sets of data into columns that are side by side without changing the actual 128x4 set itself.

请先登录,再进行评论。

更多回答(0 个)

类别

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

产品


版本

R2019a

Community Treasure Hunt

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

Start Hunting!

Translated by