creating folder in matlab
6 次查看(过去 30 天)
显示 更早的评论
how can i create a folder in matlab which will store all my text files in it
0 个评论
回答(2 个)
Chunru
2022-7-14
% create folder (in current folder)
folder = "mydir";
mkdir(folder);
% save data in a file in the folder
a = rand(3);
save(fullfile(folder, 'test.txt'), 'a', '-ascii');
% show the file
type mydir/test.txt
3 个评论
另请参阅
类别
在 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!