Hi,

Simon Blomberg wrote:
> How about this:
>
> x <- 1
> y <- 1
> mmax <- 10
>
> my.files <- paste("foo", x:mmax, ".png", sep="")
>
> for (i in my.files) {
>       png(filename=i, pointsize=20, width=600, height=600, units="px",
>       bg="#eaedd5")
>       plot(x, y)
>       dev.off()
>       x <- x+1
>       y <- y+1
> }
>   

It does the trick! Thanks.
> Normally I would avoid for loops, but I think this application is a
> legitimate use.

Please, why do you avoid looping normally? Thanks again.

Greetings,

Ricardo

-- 
Ricardo Rodríguez
Your XEN ICT Team

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to