[R-SIG-Mac] quartz.save()
Prof Brian Ripley
ripley at stats.ox.ac.uk
Mon Apr 14 17:27:33 CEST 2008
On Mon, 14 Apr 2008, Todd A. Johnson wrote:
> Hi Peter & Ricardo
>
> The same thing can be done in 2.7.0 with:
>
> quartz(type="pdf", file="/Users/username/wherever")
> plot(0,0)
> dev.off()
>
> help(quartz) for additional options
I don't think so: that does not save the current plot. You could adapt
dev.copy2pdf() to come very close (or just use it -- R's pdf device will
copy well enough unless you need exotic fonts).
I think the changes needed are from
oc$device <- pdf
oc$onefile <- FALSE
if (is.null(oc$paper))
oc$paper <- "special"
to
oc$device <- quartz
oc$type <- "pdf"
but I'm not sitting in front of a Mac.
(Had quartz(type="pdf") been working at feature freeze for 2.7.0 we might
have made this an option in dev.copy2pdf, but it was broken until
recently.)
>
>
> Best wishes,
>
> Todd
>
>
> On 4/14/08 Monday, April 14, 2008,4:18 PM, "[Ricardo Rodriguez] Your XEN ICT
> Team" <webmaster at xen.net> wrote:
>
>> Hi Peter, all,
>>
>> Peter Cowan wrote:
>>> Hello all,
>>>
>>> I'm having trouble with the quartz.save(), I know this is an
>>> undocumented function, and perhaps it is to be removed in 2.7.0.
>>> However, I find it very useful though I have been having trouble with
>>> it lately.
>>>
>>> Specifically, I get:
>>>
>>>
>>>> quartz()
>>>> plot(0,0)
>>>> quartz.save('temp.pdf')
>>>>
>>> Error in .Call("QuartzSaveContents", device, file, type, list(...)) :
>>> C symbol name "QuartzSaveContents" not in load table
>>>
>>> I know that quartz.save() has been discussed recently on the list, but
>>> I didn't see this particular issue addressed.
>>>
>>> Thanks
>>>
>>> Peter
>>>
>>> R GUI r5072
>>
>> I'm getting exactly the same behavior here. Same R.app GUI, r5072,
>> version.string R version 2.7.0 beta (2008-04-12 r45280).
>>
>> And I also find this function really useful. Sorry, I've not followed
>> previous discussions, so I am not aware of possible alternatives. Accept
>> my apologies if they are quite obvious.
>>
>> Thanks,
>>
>> Ricardo
>
> _______________________________________________
> R-SIG-Mac mailing list
> R-SIG-Mac at stat.math.ethz.ch
> https://stat.ethz.ch/mailman/listinfo/r-sig-mac
>
--
Brian D. Ripley, ripley at stats.ox.ac.uk
Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/
University of Oxford, Tel: +44 1865 272861 (self)
1 South Parks Road, +44 1865 272866 (PA)
Oxford OX1 3TG, UK Fax: +44 1865 272595
More information about the R-SIG-Mac
mailing list