Double to cell from workspace?
343 次查看(过去 30 天)
显示 更早的评论
i have a variable which is (2100*40 double) .i need to convert to each to a cell.the outpur as (2100*40 cell)
采纳的回答
更多回答(2 个)
Mischa Kim
2014-3-14
编辑:Mischa Kim
2014-3-14
A = [1 2 3; 4 5 6]; % numeric array
B = {A}; % cell array
C = mat2cell(A); % cell array
0 个评论
David Sanchez
2014-3-14
data = rand(3,5); % your data here
create cell with data
cell_data = num2cell(data);
you can also take a look at
mat2cell
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Cell Arrays 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!