[R] pdf and postscript sizes - change on each page?

From: Alex Brown <alex_at_transitive.com>
Date: Wed 27 Sep 2006 - 12:38:36 GMT


Hi All

The device commands pdf and postscript allow you to specify the width and height of a page. However, each subsequent plot is drawn on a separate page. Is there a way to change the page size part way through?

For instance, is there an equivalent to the function pdfresize below?

pdf("/tmp/1.pdf", width=6, height=6)

plot(1:10)

pdf.resize(width=8, height=5)

plot(sin, -pi, pi)

dev.off()

---

So far, the only way I can find to do this is:

pdf("/tmp/1.pdf", width=6, height=6)

plot(1:10)

dev.off()

pdf("/tmp/1.pdf", width=8, height=5)

plot(sin, -pi, pi)

dev.off()

---

however, this creates a new file - it does not append to the existing file.

I would note that the quartz device has some resize capability, when you drag the window frame.

-Alex



R-help@stat.math.ethz.ch 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. Received on Wed Sep 27 22:45:24 2006

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.1.8, at Wed 27 Sep 2006 - 13:30:06 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.