Effacer les filtres
Effacer les filtres

How to increment string

12 vues (au cours des 30 derniers jours)
Rohan Repale
Rohan Repale le 9 Avr 2013
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

Réponse acceptée

Cedric
Cedric le 9 Avr 2013
fname = sprintf('filename(%d).jpg', m) ;
saveas(C, fname) ;

Plus de réponses (0)

Catégories

En savoir plus sur Characters and Strings dans Help Center et File Exchange

Tags

Produits

Community Treasure Hunt

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

Start Hunting!

Translated by