フィルターのクリア

Cell2Mat for multiple columns

5 ビュー (過去 30 日間)
Anna
Anna 2014 年 10 月 15 日
回答済み: Azzi Abdelmalek 2014 年 10 月 15 日
If I have the 2x3x4 cell array:
g = cat(3, {1,2,3;4,5,6}, {11,12,13;14,15,16}, {21,22,23;24,25,26}, {31,32,33;34,35,36})
What is the best way to wrap this into a 2D matrix such that the matrix has 2 columns and 12 rows in each?
The first column would consist of 1,2,3,11,12,13,21,22,23,31,32,33 // The second column 4,5,6,14,15,16,24,25,26,34,35,36
Something like:
AllFrag = reshape(cell2mat(g),2,[]).'
Throws an error:
Error in cell2mat (line 119)
ct{mref{:}} = cat(cdim+1,c{mref{:},:});
and I'm not sure why.

採用された回答

Azzi Abdelmalek
Azzi Abdelmalek 2014 年 10 月 15 日

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeCell Arrays についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by