4-D array to 3-D array
1 回表示 (過去 30 日間)
古いコメントを表示
I have a 4-D array saved in a mat file like
ice_conc_monthly(:,:, year-1978, month) = d;
its is 304*448*37*12, how can i make it 3-D with 304*448*(37*12) size
0 件のコメント
採用された回答
James Tursa
2016 年 12 月 1 日
編集済み: James Tursa
2016 年 12 月 1 日
E.g.,
x = your 304 * 448 * 37 * 12 array
y = reshape(x,304,448,37*12);
Another possibility if you want those last two dimensions arranged differently is to permute them first. E.g.,
x = your 304 * 448 * 37 * 12 array
z = permute(x,[1 2 4 3]);
y = reshape(z,304,448,37*12);
0 件のコメント
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Matrices and Arrays についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!