MATLAB Answers

how to convert cell to matrix

322 views (last 30 days)
Cem SARIKAYA
Cem SARIKAYA on 28 Dec 2018
Commented: madhan ravi on 29 Dec 2018
i have 70103x1 cell array but i want to convert this to matrix i want every array open one row. briefly i want to convert this for example 70103x90 how can i do that?

  1 Comment

Akira Agata
Akira Agata on 28 Dec 2018
Does each cell contain 1x90 array? If so, cell2mat function works, as:
% 2x1 Sample cell array
C = {rand(1,90),rand(1,90)};
% cell2mat will convert it into 2x90 array
X = cell2mat(C);

Sign in to comment.

Accepted Answer

madhan ravi
madhan ravi on 29 Dec 2018
[yourcellarray{:}]

  2 Comments

madhan ravi
madhan ravi on 29 Dec 2018
Cem SARIKAYA's answer moved here for consistency:
thank you this is exactly what i want

Sign in to comment.

More Answers (0)

Sign in to answer this question.