From: Tom Short <email@example.com> To: firstname.lastname@example.org Subject: Re: org tables and R Date: Fri, 2 Jan 2009 22:34:41 +0000 (UTC) [thread overview] Message-ID: <loom.20090102T212235email@example.com> (raw) In-Reply-To: <20081230193550.GA7961@stats.ox.ac.uk> Dan Davison <davison <at> stats.ox.ac.uk> writes: > There are more details below. The code is at > > http://www.stats.ox.ac.uk/~davison/software/org-table-R/org-table-R.el This is a neat way to interface to R and to make tables more useful to me. I'm a big user of ESS/R and org-mode, and I've been looking at ways to use them together more. If you want to input an org-mode table into R, here's one way to do it with Dan's TBLR: | col1 | col2 | |------+------| | 1 | 2 | | 3 | 4 | #+TBLR: replace:t #+TBLR:: my.table <<- x This assigns the table to the global variable "my.table" in R, and because we have "replace:t", it doesn't append the table with a copy of itself. That's a little kludgy, maybe an action to give the table a name could do that a bit more readily. If you want to reverse that and take an R table and put it into an org-mode table, you can do this: | | #+TBLR:: x <- r.table If you run "org-table-R-apply" with the cursor in the brackets above, it will produce the R variable "r.table" in an org-mode table following that statement. - Tom
next prev parent reply other threads:[~2009-01-02 22:35 UTC|newest] Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top 2008-12-30 19:35 Dan Davison 2009-01-02 22:34 ` Tom Short [this message] 2009-01-22 8:09 ` Carsten Dominik 2009-01-22 13:19 ` Graham Smith [not found] <firstname.lastname@example.org> 2008-12-31 19:54 ` Tom Breton (Tehom)
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style List information: https://www.orgmode.org/ * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=loom.20090102T212235email@example.com \ --firstname.lastname@example.org \ --email@example.com \ --subject='Re: org tables and R' \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
Code repositories for project(s) associated with this inbox: https://git.savannah.gnu.org/cgit/emacs/org-mode.git This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).