Converting three-dimensional matrixes

In the folder I have 100 files. Each contains of four matrixes (three-2D and one-3D size 71 * 73 * 13). I need to obtain thirteen 3D matrixes (71*73*100). Each must consist of the same number of floor from input 3D matrixes. How can I do it automatically?

回答 (1 件)

Matt J
Matt J 2014 年 3 月 5 日
編集済み: Matt J 2014 年 3 月 5 日

2 投票

Using a loop, read each 3D array into a cell, C{i}. Then concatenate to form a four dimensional array and permute
A=permute( cat(4,C{:}) ,[1 2 4 3] );
The resulting A will be 71x73x100x13, which is an equivalent or better data organization than 13 separate matrices.

カテゴリ

タグ

質問済み:

2014 年 3 月 5 日

編集済み:

2014 年 3 月 5 日

Community Treasure Hunt

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

Start Hunting!

Translated by