From mboxrd@z Thu Jan 1 00:00:00 1970 From: Christian Moe Subject: Re: [BABEL] Define tables with names in org? Date: Thu, 09 Jan 2014 13:30:09 +0100 Message-ID: References: <52CE89A9.8060305@krugs.de> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:45451) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1W1EjR-0000NL-2e for emacs-orgmode@gnu.org; Thu, 09 Jan 2014 07:29:14 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1W1EjG-0003dt-Rs for emacs-orgmode@gnu.org; Thu, 09 Jan 2014 07:29:05 -0500 Received: from mail-forward1.uio.no ([2001:700:100:10::70]:35156) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1W1EjG-0003ZN-Ks for emacs-orgmode@gnu.org; Thu, 09 Jan 2014 07:28:54 -0500 Received: from exim by mail-out1.uio.no with local-bsmtp (Exim 4.75) (envelope-from ) id 1W1Eif-0005vZ-93 for emacs-orgmode@gnu.org; Thu, 09 Jan 2014 13:28:17 +0100 In-reply-to: <52CE89A9.8060305@krugs.de> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Rainer@krugs.de Cc: emacs-orgmode Rainer M Krug writes: > I would like to define a table with named columns and rows, so that > the table is passed to R including the column and row names - is this > possible? Yes, just use the leftmost column for row names and include the header argument :rownames yes. By default, the first row will be used for column names if followed by a hline. Without a hline, use :colnames yes. E.g.: #+name: colrownamestbl | | Alpha | Beta | Gamma | |--------+-------+------+-------| | First | A1 | B1 | C1 | | Second | A2 | B2 | C2 | | Third | A3 | B3 | C3 | #+begin_src R :var data=colrownamestbl :rownames yes :results output colnames(data) rownames(data) #+end_src #+RESULTS: : [1] "Alpha" "Beta" "Gamma" : [1] "First" "Second" "Third" Yours, Christian