emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Nick Dokos <ndokos@gmail.com>
To: emacs-orgmode@gnu.org
Subject: Re: import R data frame into org-mode table
Date: Mon, 29 Jul 2013 17:40:27 -0400	[thread overview]
Message-ID: <87a9l5avuc.fsf@gmail.com> (raw)
In-Reply-To: D4772401B9D976478C0895769BE3E792BBC0D2@MBSRV02.sgc.loc

"Cook, Malcolm" <MEC@stowers.org> writes:

>
> Indeed, thanks, and, my worked out example follows using emacs 2.18.9 and org-mode version 8.0.6
>

2.18.9?

> #+LATEX: \listoftables
> #+LaTeX_HEADER: \usepackage{longtable}
> #+name: longtabletest
> #+CAPTION: test of longtable caption
> #+begin_src R :results value :colnames yes
> data.frame(num=1:260,alpha=rep(LETTERS,10))
> #+end_src
>
> #+RESULTS:
> #+attr_latex: :environment longtable
> | num | alpha |
> |-----+-------|
> |   1 | A     |
> |   2 | B     |       
> ...

Does this really produce a table caption for you when you export to
latex? And does the attr_latex line stay there at the top of the table
when the code block is evaluated?  For me, the answers are "no" and
"no". I have to rewrite it as follows in order for it to work:

> #+begin_src R :results value :colnames yes
> data.frame(num=1:260,alpha=rep(LETTERS,10))
> #+end_src
>
> #+CAPTION: test of longtable caption
> #+attr_latex: :environment longtable
> #+RESULTS:
> | num | alpha |
> |-----+-------|
> |   1 | A     |
> |   2 | B     |

-- 
Nick

  reply	other threads:[~2013-07-29 21:40 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-16 15:19 import R data frame into org-mode table Rob Stewart
2013-07-17 22:09 ` Andreas Leha
2013-07-29 14:42   ` Rob Stewart
2013-07-29 15:35     ` Cook, Malcolm
2013-07-29 16:03       ` John Hendy
2013-07-29 17:11         ` Nick Dokos
2013-07-29 20:17         ` Cook, Malcolm
2013-07-29 21:40           ` Nick Dokos [this message]
2013-07-30 17:59             ` Cook, Malcolm
2013-07-17 22:48 ` Thomas S. Dye

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=87a9l5avuc.fsf@gmail.com \
    --to=ndokos@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    /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
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public 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).