How to increment string

I wish to do something like this...
for m=1:10,
C=%some array
C=imagesc(A);figure(gcf);
saveas(C,'filename(m).jpg');
end
Can someone help me??
Thanks, Rohan

 採用された回答

Cedric
Cedric 2013 年 4 月 9 日

0 投票

fname = sprintf('filename(%d).jpg', m) ;
saveas(C, fname) ;

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File ExchangeFile Operations についてさらに検索

製品

タグ

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by