Réf. : Re: Modifying ess-dump-filename-template for R

Gerald.Jean at spgdag.ca Gerald.Jean at spgdag.ca
Tue Nov 13 14:52:27 CET 2001


talking about "ess-insert-function-outline", which I use quite a bit, how
could we have the name of the buffer show up as the default new fonction
name when calling "ess-insert-function-outline".  For example suppose I
open a new file with name "new.function.s (or .R)", then I call
"ess-insert-function-outline" and I get the following function template.

"f" <- function()
### Author : Gérald Jean
### Date   : 13 Nov 2001, 08:46
### Purpose:
### ----------------------------------------------------------------------
### Arguments:
### ----------------------------------------------------------------------

of course I did customized the file given by the variable "ess-function-outline-file"; but I couldn't, no matter how hard I tried, to get the
"f" above replaced by "new.function", in this example.  I know this is more of an Emacs question than an ESS question but ...!


Gérald Jean
Analyste-conseil (statistiques), Actuariat
télephone            : (418) 835-4900 poste (7639)
télecopieur          : (418) 835-6657
courrier électronique: gerald.jean at spgdag.ca

"In God we trust all others must bring data"  W. Edwards Deming

Martin Maechler <maechler at stat.math.ethz.ch>@stat.math.ethz.ch le
2001/11/13 02:18:26

Veuillez répondre à Martin Maechler <maechler at stat.math.ethz.ch>

Envoyé par :   owner-ESS-help at stat.math.ethz.ch

Pour :    "Patrick Connolly" <P.Connolly at hortresearch.co.nz>
cc :  rossini at u.washington.edu, rmh at surfer.sbm.temple.edu (Rich Heiberger),
      ess-help at stat.math.ethz.ch
Objet :   Re: Modifying ess-dump-filename-template for R

>>>>> "PaCo" == Patrick Connolly <P.Connolly at hortresearch.co.nz> writes:

    PaCo> According to A.J. Rossini: |> |> >>>>> "RH" == Rich Heiberger
    PaCo> <rmh at surfer.sbm.temple.edu> writes: |> |> RH> There is no need to
    PaCo> make any changes.  When you do C-c C-d |> RH> from an *R* buffer,
    PaCo> the file comes up with a .R extension.  |> |> Part of the issue
    PaCo> might be that dumping a NULL object from S-PLUS, you |> end up
    PaCo> with a "function template", while from R, you end up with an |>
    PaCo> empty buffer.  Is this the problem, Patrick?

    PaCo> Right on.  Just after I sent that message, I noticed I hadn't
    PaCo> made that clear.  Unfortunately our email system crashed just
    PaCo> about then and I was unable to clarify.

    PaCo> There is a template file I found at one stage (but not now).  I
    PaCo> wanted that to be used.


  (defun ess-add-MM-keys ()
    "Define \"C-c f\" and force \\[ess-toggle-underscore]."
    (require 'ess-mode)
    (define-key ess-mode-map "\C-cf" 'ess-insert-function-outline))

i.e. it's   ess-insert-function-outline
that you (we) may want to use in this case.

    PaCo> Now the question is clear, we can begin.

    PaCo> Thanks

    PaCo> -- *************************************************************
    PaCo> ___ Patrick Connolly {~._.~} HortResearch Great minds discuss
    PaCo> ideas; _( Y )_ Mt Albert Average minds discuss events; (:_~*~_:)
    PaCo> Auckland Small minds discuss people.  (_)-(_) New Zealand
    PaCo> .... Anon Ph: +64-9 815 4200 x 7188
    PaCo> *************************************************************

    PaCo> ______________________________________________________ The
    PaCo> contents of this e-mail are privileged and/or confidential to the
    PaCo> named recipient and are not to be used by any other person and/or
    PaCo> organisation. If you have received this e-mail in error, please
    PaCo> notify the sender and delete all material pertaining to this
    PaCo> e-mail.  ______________________________________________________
    PaCo> -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.
    PaCo> ess-help mailing list -- To (un)subscribe, send subscribe or
    PaCo> unsubscribe (in the "body", not the subject !)  To:
    PaCo> ess-help-request at stat.math.ethz.ch
    PaCo> _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._.
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

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