Creating a table for a cell array with cell2table
Show older comments
Hi
Is there a limitation when creating a table from a cell array when the elements on a column don't have the same type ? This is the input cell array as shown in the command line:
tbl_content =
[ 9353] [ 493]
[ 7677] {1x1 cell}
[ 6931] [ 128]
and after conversion with cell2table
tbl = cell2table(tbl_content, 'VariableNames', col_names, ...
'RowNames', row_names);
I get
tbl =
ITALY BELGIUM
_____ _______
01-Jan-2010 00:00:00 9353 [493]
01-Feb-2010 00:00:00 7677 [NaN]
01-Mar-2010 00:00:00 6931 [128]
Why the first column doesn't have brackets for its elements, while the second column has ?
My intention is to put on the second cell of the second column in the cell array a NaN.
thanks Bogdan
Accepted Answer
More Answers (0)
Categories
Find more on Data Type Conversion in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!