Tom Roche Wed, 15 Feb 2012 17:43:05 -0500 >> 1 I'm plotting to PDF, so everytime I dev.off() creates a new file, >> and I want everything in one file (as does my boss :-)
>> 2 I'm doing the work on a cluster, where I very much do not have >> root, and which has a fairly minimal set of installed packages, >> so I can't just call something external like 'pdftk' to merge the >> PDFs as I go. >> 3 As part of the processing, I printf status and debug messages, >> which I don't want in my PDF(s). ilai Wed, 15 Feb 2012 16:34:34 -0700 > [Until] dev.off(), all plots will be sent to the open graphical > device [which] usually doesn't impact behavior of other output Doh! I totally missed that, and was having PDF problems for other reasons. And thanks for the self-contained example (slightly extended by me): pdf.reader -> "xpdf" pdf(file='fooout.pdf') hist(x <- rnorm(100)) y <- sin(x) print(str(y)) cat(y,file='fooout.txt') plot(x,y) dev.off() system(paste(pdf.reader, 'fooout.pdf')) system('cat fooout.txt') thanks again, Tom Roche <tom_ro...@pobox.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 and provide commented, minimal, self-contained, reproducible code.