creating folder in matlab
6 views (last 30 days)
Show older comments
how can i create a folder in matlab which will store all my text files in it
0 Comments
Answers (2)
Chunru
on 14 Jul 2022
% 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 Comments
See Also
Categories
Find more on Text Files 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!