[R-SIG-Mac] quartz.save and tilde
Simon Urbanek
simon.urbanek at r-project.org
Tue May 1 23:12:26 CEST 2007
DEnis,
On May 1, 2007, at 4:04 PM, Chabot Denis wrote:
> Until now, I've been able to use the tilde to replace "/Users/
> chabotd" in all my R scripts, be it directly or with the use of
> "paste".
>
> I am experimenting with quartz.save to produce png files to save
> the step of producing pdf and transforming them into png later. I
> need png to reduce file size for a series plots with thousands of
> points, even though I prefer vector drawings for most situations.
>
> I have not been able to find any documentation on quartz.save, but
> if I include the tilde in the file name, something that works with
> pdf or png devices, it does not work (for me) with quartz.save. I
> need to give the unabridged path.
>
> Is there a reason for this?
>
Yes, the tilde is not expanded. Why is it not expanded? Because the
author didn't think of it ;). It's fixed now.
> Also, what are the options in quartz.save? I've only managed to use
> file="path and file" and type="png" or type="pdf". I've tried to
> control resolution (res=300) but it had no effect, so for now I
> change the size of the quartz graphics when I call quartz (which
> forces me to change pointsize as well to keep proportions of text
> relative to drawing size the same.
>
file, type and device are the only options of quartz.save and the
purpose is to save the image "as-is", directly from the Quartz
window, so res doesn't make sense here (it would no longer be a
direct snapshot of the window). I guess it would be possible to do
what you described, though (Quartz->PDF->PNG of any resolution). I'll
see if there is an easy way to do that ...
Cheers,
Simon
More information about the R-SIG-Mac
mailing list