[R] How do I save a figure with postcript()

Peter Marx peter at beck-marx.de
Sun Jan 6 09:16:49 CET 2002


On Sun, Jan 06, 2002 at 12:45:22AM -0200, hzi at uol.com.br wrote:
[...]
> 	Then, I went on to save it as a .ps and an .eps file. As I
> understood in the R-intro.pdf:
> 
> > postscript("/home/synthespian/r_graphics_test_plot.ps", horizontal=FALSE, height=5, pointsize=10)
> > postscript("/home/synthespian/r_graphics_test_plot.eps", horizontal=FALSE, height=5, pointsize=10)
> 
> 	But this produced a file with 0 Kb (as loaded with xv)!
[...]

Hi,
you have to put:

dev.off()

after your plot statement.


> 	And what are some good parameters - height and pointsize?
> 	Obviously, this is the way to go about it. 
Try without any parameters but the filename. 
It depends on what you want to do with your ps-file.

P.S You can scale ps-files _after_ the creation in size.

-- 
Mit freundlichen Grüßen:
+--------------------------------------------------------------+
| Peter Marx                                                   |
| E-Mail: peter at beck-marx.de |  Adresse: Hünenbergweg 2a       |
| Tel.  : 07261/1 68 23      |           74889 Sinsheim        |
+--------------------------------------------------------------+
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._



More information about the R-help mailing list