"<=" in R or S

Hans Ehrbar ehrbar at econ.utah.edu
Tue Oct 3 04:58:06 CEST 2000


Pierre, the function bound to a key must be an interactive
command.  Furthermore, I did not have success assigning
anything to control-=, but I found that Ctrl-^ was
unassigned in my version of ess-mode, therefore the
following worked for me:

  (defun R-equals () (interactive) (insert " <- "))
  (define-key ess-mode-map "\C-^" 'R-equals)

>>>>> On Mon, 02 Oct 2000 15:12:35 -1000, Pierre Kleiber
>>>>> <pkleiber at honlab.nmfs.hawaii.edu> said:


> Many of you have probably seen the discussion in the R-help list
> with the subject:
>    [R] Unreadable code: was the underscore ("_") in variables

> I thought I should be able to bind an unused key combination to
> a function to insert "<-", and then I could gloat about another
> advantage of running R from ess.  I put the following in .emacs:

>   (defun R-equals () (insert "<-"))
>   (global-set-key [?\C-=] 'R-equals)

> But all I get from C-= is "Wrong type argument, commandp, R-equals"
> in the Minibuffer.  Being lisp literate enough only to get into
> trouble, I'm stumped at this point.  Does anyone have any suggestions?
>    Thanks, Pierre

-- 
Hans G. Ehrbar   http://www.econ.utah.edu/ehrbar   ehrbar at econ.utah.edu
Economics Department, University of Utah     (801) 581 7797 (my office)
1645 Campus Center Dr., Rm 308               (801) 581 7481 (econ office)
Salt Lake City    UT 84112-9300              (801) 585 5649 (FAX)

-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
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