[Help] writetable text alignment and saving pre 0
이전 댓글 표시
Hello Everyone,
I am incurring a little problem on execution of following code
filename='myExcelFile.xlsx';
myTable = cell2table(Dataset, 'VariableNames', header);
writetable(myTable, filename, 'WriteVariableNames', true);
By writing a table to excel, it removes pre 0. I mean it saves 0409 to 409. Is there any way to preserve initial zeros?
Second, can we sort the data in columns as well? For instance, it sorts Text data to flush left and numerical data to flush right. Can we initialize a directon for that?
Any help would be appreciated.
Thank you :-)
댓글 수: 3
Adam Danz
2019년 8월 7일
Waqar Ali Memon's comment moved here from the answers section.
Adam Danz
2019년 8월 7일
Sometimes there's a glitch in the system that allows for >1 answer to be accepted within a quick window of time but generally only 1 acceptance is allowed. That discussion is here:
Waqar Ali Memon
2019년 8월 7일
채택된 답변
추가 답변 (1개)
카테고리
도움말 센터 및 File Exchange에서 Data Import from MATLAB에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!