[R] Fwd: Re: R grahics: Save as hangs computer

From: Richard M. Heiberger <rmh_at_temple.edu>
Date: Fri 05 Jan 2007 - 04:30:56 GMT


R is actually smarter than that. The bounding box is square.
>From

plot(1:10)
dev.copy2eps(file="tmp.eps")

The bounding box (which you can see by opening tmp.eps in emacs) is %%BoundingBox: 0 0 517 517
and LaTeX will therefore interpret it correctly. GSview is misleading you since it puts that square region at one end of the rectangle implied by the GSview setting of media at "letter" or "A4".

In addition to most likely not needing to crop, there are many ways to crop the image.

If cropping is just to get rid of white space, I usually do it in LaTeX by adding some negative space
\height{-2in}
inside the figure environment.

Rich

>Opening the eps file in GSview I noticed that there is still a lot of white
>space in the bounding box which creates empty space when I want to include
>the image into a tex document. Is there a way to crop the image to remove
>the white space before including it in a document?



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 Fri Jan 05 15:36:35 2007

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 Fri 05 Jan 2007 - 05:30:24 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.