Running the Same code for Multiple Files in a Folder
5 ビュー (過去 30 日間)
古いコメントを表示
Is it possible to use the same code for Multiple Files in a Folder and save its output at particular location.
0 件のコメント
回答 (1 件)
Chunru
2021 年 6 月 17 日
Here is a schetch of the solution:
fn = dir('a*.txt'); % obtain the file information 'a*.txt'. make your own modification
for i=1:length(fn) % loop through all the selected files in the folder
filename = fn(i).name;
% Perform any operation depending on the filename
% Save the results anaywhere you like
end
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Adding custom doc についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!