Suggested value for ess-retr-lastvalue-command for R

Bjørn-Helge Mevik bhm at math.uio.no
Thu Jun 8 11:22:56 CEST 2000


(I'm using ess-5.1.13 and R 1.0.0.)

essd-r.el defines the value of ess-retr-lastvalue-command to be
".Last.value <- get(\".ess.lvsave\",inherits=T)\n", which assigns a
value to .Last.value in .GlobalEnv.  However, R expects the value to be
stored in package:base, and if it is assigned in .GlobalEnv, the special
function of .Last.value is lost (until the value is removed again).

I suggest the following value for ess-retr-lastvalue-command:
"invisible(get(\".ess.lvsave\",inherits=T))\n".  I'm not a great R,
elisp or ESS programmer, but it seems to work for me.


Btw. I noticed there are a couple of 

  (if (or (equal window-system 'w32) (equal window-system 'win32))
      (sleep-for 0.5))

and a

  (if (or (equal window-system 'w32) (equal window-system 'win32))
      (sleep-for 4))        ;this much time is needed for
                            ;ess-create-object-name-db on PC
 
in the ess-command function.  I'm just curious: Why are the sleep's
needed?


-- 
Bjørn-Helge Mevik   <bhm at math.uio.no>
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
ess-help mailing list -- To (un)subscribe, send
subscribe	or	unsubscribe
(in the "body", not the subject !)  To: ess-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._



More information about the ESS-help mailing list