Change of saving folder with each iteration
조회 수: 6 (최근 30일)
이전 댓글 표시
I want to set path where to save a file. But this saving function is in loop and name of saving variable is changing every iteration.
for k....
for l......
filename = [ 'delta',num2str(l) ,num2str(k), '.mat'];
save(filename,'delta')
end
end
and i want to change name of folder where to save also with every iteration.
filepath=['c:\....\' int2str(l) '\'];
Thanks for help!!
댓글 수: 0
채택된 답변
Walter Roberson
2013년 4월 22일
Change the
save(filename,'delta')
to
save(fullfile(filepath, filename), 'delta');
댓글 수: 0
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Logical에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!