[R-SIG-Mac] quartz.save() and ESS (was: Linux user asks: What about that Editor you have ...)

Steve Revilak steve at srevilak.net
Sat May 16 00:09:41 CEST 2009


marc_schwartz> Can you describe the problems that you are having with
marc_schwartz> Emacs/ESS?
marc_schwartz> 
marc_schwartz> I have played around with the editor in R.app on OSX,
marc_schwartz> but I find the Emacs/ESS combination to be superior. In
marc_schwartz> fact, I build Emacs 23 from CVS to have a 'real' Emacs
marc_schwartz> on OSX, as opposed to the quirky behavior of Aquamacs.

I'd like to ask a tangental question.

I'm running Mac OS X 10.4.11 on a G5 PPC, and I also build Emacs from
source.

   GNU Emacs 22.3.1 (powerpc-apple-darwin8.11.0, Carbon Version 1.6.0) of 2009-03-28 on spud.local

I've recently started experimenting with ESS version 5.3.11, which I'm
using in conjunction with R 2.9.0.  About half of my time is spent in
R.app (console and/or built-in editor), and the other half is spent
with ESS.

One thing I miss with ESS is quartz.save().  From ESS, I can open a
quartz() device and plot to it, but quartz.save() gives the error
'could not find function "quartz.save"'.  Here's an example:

    # output starting from M-x R

    R version 2.9.0 (2009-04-17)
    Copyright (C) 2009 The R Foundation for Statistical Computing
    ISBN 3-900051-07-0

    R is free software and comes with ABSOLUTELY NO WARRANTY.
    You are welcome to redistribute it under certain conditions.
    Type 'license()' or 'licence()' for distribution details.

      Natural language support but running in an English locale

    R is a collaborative project with many contributors.
    Type 'contributors()' for more information and
    'citation()' on how to cite R or R packages in publications.

    Type 'demo()' for some demos, 'help()' for on-line help, or
    'help.start()' for an HTML browser interface to help.
    Type 'q()' to quit R.

    [Previously saved workspace restored]

    > options(STERM='iESS', editor='emacsclient')
    > quartz();
    > plot(1:10, type="l")
    > quartz.save("foo.png");
    Error: could not find function "quartz.save"

dev.copy() works, though.

   > dev.copy(device=png, filename="foo.png")
   quartz_off_screen
                   3
   > dev.off()
   quartz
        2

Is there a way to have quartz.save() work from within ESS?

Steve



More information about the R-SIG-Mac mailing list