I have a cell c and an array nums, which are used to create a table T. The table is then written to a csv file test.csv.
c = {'6 - 7'; '6 - 8'; '6 - 9'; '6 - 10'; '6 - 11'; '6 - 12'; '6 - 13';
'7 - 8'; '7 - 9'; '7 - 10'; '7 - 11'; '7 - 12'; '7 - 13'; '8 - 9'; '8 - 10'; '8 - 11';
'8 - 12'; '8 - 13'; '9 - 10'; '9 - 11'; '9 - 12'; '9 - 13'; '10 - 11'; '10 - 12';
'10 - 13'; '11 - 12'; '11 - 13'; '12 - 13'};
nums = (1:length(c))';
T = table(c, nums);
writetable(T, 'test.csv');
When I write the table to a csv file and open it in Excel, the entries in c are displayed as a date (ie '6 - 7' is displayed as '7-June' in Excel). I want the entries to appear exactly as the characters that are in d. Is this an issue with MATLAB or is this on the Excel side?
0 Comments
Sign in to comment.