[R] FW: S+ Script Files for R???
A.J. Rossini
rossini at blindglobe.net
Tue May 13 07:55:41 CEST 2003
(Ted Harding) <Ted.Harding at nessie.mcc.ac.uk> writes:
> Despite recent replies (though mind you I'm not a user of ESS so can't
> comment on what that offers, though my prior guess is that people who
> like the pointy-clicky mindset of Windows are unlikely to adapt painlessly
> to emacs), you can in fact do something very similar with X windows in
> Unix/Linux. I have often done it, both with script files I'm writing
> myself and especially with example scripts (sometimes complex applications
> such as in the README for Schafer's MIX, working through it task by task
> to see what happens along the way, sometimes the mini-examples which are
> appended to the help files for R functions).
What you are describing is exactly what ESS is designed to make much
simpler...
> 2. You have another file with "script" (i.e. R code) open in another
> X window (you may be viewing the file with say 'less' or you may
> be editing it using whatever text editor you prefer). Then:
So, you split Emacs to have 2 buffers, one with R and the other (or
many others) with source files). In the next version of ESS, John
Fox's simple split screen will be available, along with toolbar
buttons for R, S-PLUS, and (hopefully) SAS.
> 3. Position the mouse pointer to the beginning of the code you want to
> highlight, press the left button, and drag it to the end, thus
> highlighting the whole block. Then:
C-c C-r to send it to R.
Or if it's within a function block, C-c C-f to send it to R
Or to send the current line, or buffer, or send line and step to the
next non-comment, and well...
> 5. You have been paging through a help file in the R window, and at the
> end there is some R code you want to try. While the pager is still up,
> highlight the block of code. Close the pager (e.g. with "q"). Then
> middle-click in the R window. Same effect as (4) above.
C-c C-v object.to.get.help.on
Press "l" on the example code to evaluate one line and step to the
next.
best,
-tony
--
A.J. Rossini rossini at u.washington.edu http://software.biostat.washington.edu/
Biostatistics, U Washington and Fred Hutchinson Cancer Research Center
FHCRC:Tu: 206-667-7025 (fax=4812)|Voicemail is pretty sketchy/use Email
UW : Th: 206-543-1044 (fax=3286)|Change last 4 digits of phone to FAX
CONFIDENTIALITY NOTICE: This e-mail message and any attachments ... {{dropped}}
More information about the R-help
mailing list