how to export numerical values to ASCII format
67 ビュー (過去 30 日間)
古いコメントを表示
Actually I am having a hard time to do it. I use R nowadays i forgot how to export my data in matlab. I searched and I could not find a way to do it.
I tried
save('TheNameYouwant.txt','TheNameOfFile', '-ascii');
but this is not what I want. I want to have the output as Tab Delimited text
1 件のコメント
shima inanloo
2019 年 8 月 1 日
hi niki !
try this :
foe example, you have the result Zx and the input variables are X :
A = [X;Zx];
fileID = fopen('f.txt','w');
fprintf(fileID,'%6s %12s\n','X','A');
fprintf(fileID,'%6.2f %12.8f\n',A);
fclose(fileID);
I hope it will help you.
採用された回答
Image Analyst
2016 年 11 月 4 日
Try dlmwrite
dlmwrite('TheFileNameYouWant.txt', yourMatrix, '\t');
0 件のコメント
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Text Files についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!