[R] Turning control back over to the terminal

From: Ross Boylan <ross_at_biostat.ucsf.edu>
Date: Tue 14 Feb 2006 - 09:26:54 EST


I'm invoking R from withing a shell script like this R --no-save --no-restore --gui=none > `hostname` 2>&1 <<BYE # various commands here
BYE I would like to regain control from the invoking terminal at some point. I tried source(stdin()) but got a syntax error, presumably stdin is the little shell here snippet (the part between <<BYE and BYE).

Is there some way to accomplish this? I am trying to regain control inside an R session that has been launched inside an MPI environment (and I'm usually running inside emacs). This is on a Mac OS X cluster.

I suppose there might be a way to do this with expect, but I'm hoping for something simpler. Potentially, I could make the script itself act differently on the head node (the only one I want to debug right now), including changing the redirection there.

-- 
Ross Boylan                                      wk:  (415) 514-8146
185 Berry St #5700                               ross@biostat.ucsf.edu
Dept of Epidemiology and Biostatistics           fax: (415) 514-8150
University of California, San Francisco
San Francisco, CA 94107-1739                     hm:  (415) 550-1062

______________________________________________
R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Received on Tue Feb 14 09:34:36 2006

This archive was generated by hypermail 2.1.8 : Fri 03 Mar 2006 - 03:42:29 EST