Re: [R] vector in filename

2008-04-18 Thread [Ricardo Rodriguez] Your XEN ICT Team
Mark, Mark Leeds wrote: > Oh, I'm sorry that didn't work. If you have time, can you resend it to me if > you still have it ( I don't ) cause I'd like to see why. Thanks. My fault! It does work! I've tried it this morning quickly, before leaving my SOHO, and it seems I was making any mistake. It

Re: [R] vector in filename

2008-04-18 Thread [Ricardo Rodriguez] Your XEN ICT Team
Hi Richard, thanks for your input! Richard Rowe wrote: > which figures if you look at what you are doing line by line ... try it > > > try something like: > > max=10 > > for (i in 1:max){ > myfiles <- paste("foo", i, ".png", sep="") # generates names > foo1.png, foo2.png, etc > png(file=m

Re: [R] vector in filename

2008-04-18 Thread [Ricardo Rodriguez] Your XEN ICT Team
Thanks Hadley, hadley wickham wrote: > Have you looked at ?png : > > filename: the name of the output file. The page number is substituted > if a C integer format is included in the character string, as > in the default. (The result must be less than 'PATH_MAX' > cha

Re: [R] vector in filename

2008-04-18 Thread hadley wickham
On Thu, Apr 17, 2008 at 8:05 PM, [Ricardo Rodriguez] Your XEN ICT Team <[EMAIL PROTECTED]> wrote: > Hi, > > I am trying to generate a group of graphics with an iteration. Some > thing like this... > > x=1 > y=1 > max=10 > myfiles <- paste("foo", x:max, ".png", sep="") > while (x =< max) >

Re: [R] vector in filename

2008-04-18 Thread [Ricardo Rodriguez] Your XEN ICT Team
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

Re: [R] vector in filename

2008-04-17 Thread Simon Blomberg
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 } Normally I woul