Concatenate cell array along one dimension

11 visualizzazioni (ultimi 30 giorni)
Xh Du
Xh Du il 4 Lug 2017
Risposto: KSSV il 4 Lug 2017
Hi all,
I have a cell array like this:
cellA =
[12x2 double] [12x2 double] [12x2 double]
[12x2 double] [12x2 double] [12x2 double]
What I want is to concatenate cellA along dimension 2, so I get a new cell like this:
cellB =
[12x6 double]
[12x6 double]
Any ideas how to obtain cellB? Thanks!

Risposta accettata

KSSV
KSSV il 4 Lug 2017
cellB = mat2cell(cell2mat(cellA),[12 12]);

Più risposte (0)

Categorie

Scopri di più su Creating and Concatenating Matrices in Help Center e File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by