emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Nick Dokos <nicholas.dokos@hp.com>
To: Andreas Leha <andreas.leha@med.uni-goettingen.de>
Cc: nicholas.dokos@hp.com, emacs-orgmode@gnu.org
Subject: Re: table not returned
Date: Wed, 28 Mar 2012 08:45:38 -0400	[thread overview]
Message-ID: <16747.1332938738@alphaville> (raw)
In-Reply-To: Message from Andreas Leha <andreas.leha@med.uni-goettingen.de> of "Wed, 28 Mar 2012 13:45:38 +0200." <87zkb1c5jx.fsf@med.uni-goettingen.de>

Andreas Leha <andreas.leha@med.uni-goettingen.de> wrote:

> 
> Hi Bastien,
> 
> thanks for looking into this!
> 
> 
> Bastien <bzg@gnu.org> writes:
> 
> > Andreas Leha <andreas.leha@med.uni-goettingen.de> writes:
> >
> >> #+begin_src R :results table
> >>   data.frame(parameter=c("parameter", "", "param1"),
> >>              mean=c("mean  sd", "", "1.1  0.1"),
> >>              median=c("median", "(minimum;maximum)", "1 (1;2)"))
> >> #+end_src
> >>
> >> #+results:
> >
> > I can't test this because of the  character.
>                                  ^^^^^
> This character got lost on the mailing list.  I guess the offending
> character was the plus-minus character.
> 
> This should be testable, I hope:
> 
> ,----
> | #+begin_src R :results table
> |   data.frame(parameter=c("parameter", "", "param1"),
> |              mean=c("mean +- sd", "", "1.1 +- 0.1"),
> |              median=c("median", "(minimum;maximum)", "1 (1;2)"))
> | #+end_src
> | 
> | #+results:
> `----
> 
> Again, this works as expected, if "(minimum" is replaced by "minimum".
> 

This happens in org-babel-import-elisp-from-file, when org-babel-string-read
is mapped on each row. To wit:

(org-babel-string-read "foo)") --> "foo)"

but

(org-babel-string-read "(foo)") --> Error

The backtrace for the error says:

,----
| Debugger entered--Lisp error: (void-function foo)
|   (foo)
|   eval((foo))
|   (if (and (not inhibit-lisp-eval) (member (substring cell 0 1) (quote ("(" "'" "`" "[")))) (eval (read cell)) (if (string= (substring cell 0 1) "\"") (read cell) (progn (set-text-properties 0 (length cell) nil cell) cell)))
|   (or (org-babel-number-p cell) (if (and (not inhibit-lisp-eval) (member (substring cell 0 1) (quote ("(" "'" "`" "[")))) (eval (read cell)) (if (string= (substring cell 0 1) "\"") (read cell) (progn (set-text-properties 0 (length cell) nil cell) cell))))
|   (if (and (stringp cell) (not (equal cell ""))) (or (org-babel-number-p cell) (if (and (not inhibit-lisp-eval) (member (substring cell 0 1) (quote ("(" "'" "`" "[")))) (eval (read cell)) (if (string= (substring cell 0 1) "\"") (read cell) (progn (set-text-properties 0 (length cell) nil cell) cell)))) cell)
|   org-babel-read("(foo)")
|   org-babel-string-read("(foo)")
`----

Nick

  reply	other threads:[~2012-03-28 12:46 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-03-27 20:02 table not returned Andreas Leha
2012-03-27 20:27 ` Bastien
2012-03-28 11:45   ` Andreas Leha
2012-03-28 12:45     ` Nick Dokos [this message]
2012-03-28 13:26       ` Andreas Leha
2012-03-28 14:20         ` Nick Dokos
2012-04-03  6:21           ` Bastien

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=16747.1332938738@alphaville \
    --to=nicholas.dokos@hp.com \
    --cc=andreas.leha@med.uni-goettingen.de \
    --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).