[TxMt] Bundles: R; LaTeX deep include parsing
Alan Schussman
alan at schussman.com
Tue May 2 00:05:08 UTC 2006
On May 1, 2006, at 4:55 PM, Peter Cowan wrote:
> You can make these yourself. I did for '<-' which I assigned to
> space-tab. I rarely use '->' except interactively. What other
> snippets have people written for R?
I've done the same, but assigned it to _, which comes from ESS.
> I would like a quicker way to send the current selection to R.app. I
> don't know if this is possible, but the current method can be sluggish
> for longer scripts.
I use the following for long selections of code. It seems R.app
doesn't always handle lots of code well. This command saves the
selected code to a temp file and then source()s it in R. It's a bit
roundabout, but works great.
echo "$TM_SELECTED_TEXT" > /tmp/Rcmd.txt
osascript -e 'tell application "R" to activate' -e "tell application
\"R\" to cmd \"source('/tmp/Rcmd.txt', echo=TRUE)\""
-Alan
More information about the textmate
mailing list