From mboxrd@z Thu Jan 1 00:00:00 1970 From: Dan Davison Subject: Re: Footnotes and R output when exporting to HTML or Latex Date: Wed, 28 Jan 2009 20:14:07 -0500 Message-ID: <20090129011407.GB7878@stats.ox.ac.uk> References: <2c75873c0901210739v77a6d347g8ab78d36ec0640a1@mail.gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LSLTx-0000AK-5H for emacs-orgmode@gnu.org; Wed, 28 Jan 2009 20:14:13 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LSLTv-00006P-9g for emacs-orgmode@gnu.org; Wed, 28 Jan 2009 20:14:12 -0500 Received: from [199.232.76.173] (port=48897 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LSLTv-00006B-3o for emacs-orgmode@gnu.org; Wed, 28 Jan 2009 20:14:11 -0500 Received: from markov.stats.ox.ac.uk ([163.1.210.1]:61569) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1LSLTu-0005GE-Lf for emacs-orgmode@gnu.org; Wed, 28 Jan 2009 20:14:10 -0500 Content-Disposition: inline In-Reply-To: <2c75873c0901210739v77a6d347g8ab78d36ec0640a1@mail.gmail.com> 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: Graham Smith Cc: emacs-orgmode@gnu.org On Wed, Jan 21, 2009 at 03:39:36PM +0000, Graham Smith wrote: > Mmmm, so busy concerened about the graphics I didn't realise I had > such a major issue with footnotes. > > I am pasting R output into an org file which comes in like: > > > names(gq3hazard) > > [1] "H1a" "H1b" "H1c" "H2a" "H2b" "H2c" "H3a" "H3b" > > [9] "H3c" "H3d" "H4a" "H4b" "H4c" "H5a" "H5b" "H5c" > > [17] "Htotal" Hi Graham, An alternative might be to format output like this as an org table? As Tom Short pointed out in another thread, you can use org-tblR.el (was org-table-R.el) in a trivial way to do that without any copy/pasting. For example you could use any of the following || #+TBLRR: x <- names(gq3hazard) || #+TBLRR: x <- t(names(gq3hazard)) || #+TBLRR: x <- cbind(seq(length(gq3hazard)), names(gq3hazard)) With point in the #+TBLRR line, org-tblR-apply produces respectively | | |--------| | H1a | | H1b | | H1c | | H2a | | H2b | | H2c | | H3a | | H3b | | H3c | | H3d | | H4a | | H4b | | H4c | | H5a | | H5b | | H5c | | Htotal | #+TBLRR: x <- names(gq3hazard) | | | | | | | | | | | | | | | | | | |-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+--------| | H1a | H1b | H1c | H2a | H2b | H2c | H3a | H3b | H3c | H3d | H4a | H4b | H4c | H5a | H5b | H5c | Htotal | #+TBLRR: x <- t(names(gq3hazard)) | | | |----+--------| | 1 | H1a | | 2 | H1b | | 3 | H1c | | 4 | H2a | | 5 | H2b | | 6 | H2c | | 7 | H3a | | 8 | H3b | | 9 | H3c | | 10 | H3d | | 11 | H4a | | 12 | H4b | | 13 | H4c | | 14 | H5a | | 15 | H5b | | 16 | H5c | | 17 | Htotal | #+TBLRR: x <- cbind(seq(length(gq3hazard)), names(gq3hazard)) Dan http://www.stats.ox.ac.uk/~davison/software/org-tbl-R/org-tblR.el (NB The code now uses TBLRR: instead of TBLR::) p.s. [Explanation if required/interested : TBLRR lines contain R code that create an R variable called `x' that gets output to the org buffer as an org table. In these cases a degenerate org table (||) is provided, and the R code doesn't use it when creating the variable x. For non-R users: "<-" is the assignment operator in R (you can also use "="), cbind sticks two vectors together column-wise, t is the transpose function.] > > > I suspect some of you are ahead of me, becasue the Org mode export > takes these to be footnotes so in the PDF I get > > > names(gq3hazard) > 1 > "H1a" "H1b" "H1c" "H2a" "H2b" "H2c" "H3a" "H3b" > $??9$ "H3c" "H3d" "H4a" "H4b" "H4c" "H5a" "H5b" "H5c" > $??17$ "Htotal" > > > with a footnote > > 1 > 5 3 7 > library(boot) > medianCI(na.omit(H1b)) > > I have no idea where the >medianCI bit has come from but looking > through the file, the spurious footnotes seems to be causing havoc > with the layout. > > > Is it possible to disable the footnote feature and then explicityly > tell orgmode that a specific instance of square brackets should be > interpreted as a footnote. > > Thanks, > > Graham > > > _______________________________________________ > Emacs-orgmode mailing list > Remember: use `Reply All' to send replies to the list. > Emacs-orgmode@gnu.org > http://lists.gnu.org/mailman/listinfo/emacs-orgmode -- http://www.stats.ox.ac.uk/~davison