Reshaping a cell array

3 ビュー (過去 30 日間)
L'O.G.
L'O.G. 2022 年 11 月 23 日
編集済み: L'O.G. 2022 年 11 月 23 日
I have a cell of cells, where each internal cell is a vector of numbers of type double. How can I reshape this in a less cumbersome way, so that I have one cell with its elements consisting of each vector (where the vectors in the first cell-within-a-cell come first, followed by the vectors in the second cell-within-a-cell, etc.)?

採用された回答

Voss
Voss 2022 年 11 月 23 日
C = {{[1 2 3]} {[4 5 6 7]} {[8 9]}}
C = 1×3 cell array
{1×1 cell} {1×1 cell} {1×1 cell}
C = [C{:}]
C = 1×3 cell array
{[1 2 3]} {[4 5 6 7]} {[8 9]}

その他の回答 (0 件)

カテゴリ

Find more on Matrices and Arrays in Help Center and File Exchange

製品


リリース

R2021b

Community Treasure Hunt

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

Start Hunting!

Translated by