[Rd] Is an R sub-session somehow possible?
simon.urbanek at r-project.org
Tue Sep 7 20:23:44 CEST 2010
On Sep 7, 2010, at 2:06 PM, ghostwheel wrote:
> I wrote the interface between R and TeXmacs. Recently, I added tab
> completion. However, there is one slight problem. In order to enable easy
> interaction with R, I (I.e. my program) interact with the command-line
> interface. This means that the user can invoke demo(), and then R will
> interact with the user and ask to press enter.
> It also means that the user can enter
> and then R will respond with '+'.
> The problem is this: the way I implemented tab completion is calling an R
> function that creates the completion. But, while in the middle of user
> input, I can't call a function.
Why not? After the "+" prompt you're back in ReadConsole so it's safe.
> I guess that ESS for emacs has the same problem. when I enter "a<-c(3,4",
> and then on the next line try to do tab completion, ESS replies that 'ESS
> process is not ready. Finish your command before trying again'.
> Of course while interacting with R on the command line, tab completion does
> So, the question is - is there any way to interrupt the current input to R,
> call a function, get the return value, and then continue with the input
> where it was? To do something similar to what pressing 'tab' in R does
> internally? Something like the equivalent of ctrl-Z for a shell?
> View this message in context: http://r.789695.n4.nabble.com/Is-an-R-sub-session-somehow-possible-tp2530174p2530174.html
> Sent from the R devel mailing list archive at Nabble.com.
> R-devel at r-project.org mailing list
More information about the R-devel