a little searching would have found: ?file.exists
On Sun, Apr 18, 2010 at 7:54 PM, chrisli1223 <chri...@austwaterenv.com.au>wrote: > > Hi everyone, > > I have written a script which exports my graphs as a PDF file using the > function pdf(). > > For instance, I run the script and it exports a PDF called "version 1". > Then, I have got a new dataset and want to run the script again. What it > usually does is overwriting "version 1". But I want it to check if "version > 1" already exists. If so, then I want the new graphs to be exported as > "version 2", and so on. > > Is it possible to do it in R? > > Thanks in advance, > Chris > -- > View this message in context: > http://n4.nabble.com/Exporting-PDF-tp2015263p2015263.html > Sent from the R help mailing list archive at Nabble.com. > > ______________________________________________ > 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<http://www.r-project.org/posting-guide.html> > and provide commented, minimal, self-contained, reproducible code. > -- Jim Holtman Cincinnati, OH +1 513 646 9390 What is the problem that you are trying to solve? [[alternative HTML version deleted]] ______________________________________________ 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.