i have a variable which is (2100*40 double) .i need to convert to each to a cell.the outpur as (2100*40 cell)

 Akzeptierte Antwort

Weitere Antworten (2)

Mischa Kim
Mischa Kim am 14 Mär. 2014
Bearbeitet: Mischa Kim am 14 Mär. 2014

1 Stimme

Sandy, use mat2cell, or, simply, curly braces:
A = [1 2 3; 4 5 6]; % numeric array
B = {A}; % cell array
C = mat2cell(A); % cell array
David Sanchez
David Sanchez am 14 Mär. 2014

0 Stimmen

data = rand(3,5); % your data here
create cell with data
cell_data = num2cell(data);
you can also take a look at
mat2cell

Kategorien

Gefragt:

am 14 Mär. 2014

Kommentiert:

SRI
am 14 Mär. 2014

Community Treasure Hunt

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

Start Hunting!

Translated by