From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Eric Schulte" Subject: Re: [Bug][BABEL][R] Headers of the tables are not recognized during the export. Date: Mon, 04 Apr 2011 11:36:50 -0600 Message-ID: <87bp0l7wb1.fsf@gmail.com> References: Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from [140.186.70.92] (port=53144 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Q6niE-0006Cj-Lt for emacs-orgmode@gnu.org; Mon, 04 Apr 2011 13:38:31 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Q6nhy-0000Jq-3E for emacs-orgmode@gnu.org; Mon, 04 Apr 2011 13:36:58 -0400 Received: from mail-iy0-f169.google.com ([209.85.210.169]:40021) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Q6nhx-0000Jk-Ux for emacs-orgmode@gnu.org; Mon, 04 Apr 2011 13:36:58 -0400 Received: by iyf13 with SMTP id 13so7984226iyf.0 for ; Mon, 04 Apr 2011 10:36:56 -0700 (PDT) In-Reply-To: (Vitalie Spinu's message of "Mon, 04 Apr 2011 17:43:59 +0200") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Vitalie Spinu Cc: emacs-orgmode@gnu.org Vitalie Spinu writes: > Hello everyone! > > Have a file like this: > -------------------------------------------- > #+OPTIONS: H:3 num:nil toc:2 \n:nil @:t ::t |:t ^:{} -:t f:t *:t TeX:t LaTeX:t skip:t d:(HIDE) tags:not-in-toc > #+BABEL: :exports both :session *R* :cache no > #+TBLNAME: Chuah07 > | condition | Mean.offer | > |-----------+------------| > | 1.MMM | 48.49 | > | 2.MMU | 42.59 | > | 3.MUM | 44.87 | > | 4.UMU | 46.43 | > | 5.UUM | 44.15 | > | 6.UUU | 43.80 | > | MAL | 46.28 | > | UK | 44.1 | > | All | 45.29 | > > > #+begin_src R :var data=Chuah07 :results output > str(data) > #+end_src > > -------------------------------------------- > > If I run html export C-c C-e b, the output like this: > > 'data.frame': 9 obs. of 2 variables: > $ V1: chr "1.MMM" "2.MMU" "3.MUM" "4.UMU" ... > $ V2: num 48.5 42.6 44.9 46.4 44.1 ... > > which means the header is not recognized. > > In contrast if I run C-c C-c on the block everything is fine: > > #+results > : 'data.frame': 9 obs. of 2 variables: > : $ condition : chr "1.MMM" "2.MMU" "3.MUM" "4.UMU" ... > : $ Mean.offer: num 48.5 42.6 44.9 46.4 44.1 ... > Thanks for catching this, I've just pushed up a fix for this issue. The column headers were being lost during the export processing. > > > Also if I use :cache yes header. The html export recomputes the block. > Wouldn't it be reasonable to have the exporter take into account the :cache > header? > The exporter *does* take into account the :cache header, however, due to the error above, the values of the inputs to the block of R code were different on export than on interactive evaluation, so the cache was invalidated as if the contents of the table had changed. Cheers -- Eric > > Thanks, > Vitalie.