emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Aaron Ecay <aaronecay@gmail.com>
To: "Thomas S. Dye" <tsd@tsdye.com>, Rainer M Krug <r.m.krug@gmail.com>
Cc: Org-mode <emacs-orgmode@gnu.org>, "Charles C. Berry" <ccberry@ucsd.edu>
Subject: Re: ob-R, problem with try/catch
Date: Thu, 23 Apr 2015 23:39:42 +0100	[thread overview]
Message-ID: <87h9s65v0x.fsf@gmail.com> (raw)
In-Reply-To: <m27ft2db28.fsf@tsdye.com>

Hi Tom,

2015ko apirilak 23an, "Thomas S. Dye"-ek idatzi zuen:
> 
> IIRC :results output graphics is needed for the ggplot package.

Hmm.  This is the case if the code is *not* evaluated in a session.  In
a session, either value or output result types work.  (All this has been
tested with a recent master version.)  An unfortunate situation – IMO
the value type ought to work outside of a session, provided that the
value of the last expression in the block is a ggplot object.

Here’s a code block that can be adapted to test various combinations:

#+begin_src R :results output graphics :file foo.png :session *foo*
  library(ggplot2)
  ggplot(data.frame(x = rnorm(10), y = rnorm(10)),
         aes(x = x, y = y)) +
    geom_point()
#+end_src

-- 
Aaron Ecay

  reply	other threads:[~2015-04-23 22:39 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-22 22:03 ob-R, problem with try/catch Thomas S. Dye
2015-04-23  2:23 ` Charles C. Berry
2015-04-23  5:40   ` Rainer M Krug
2015-04-23 15:53     ` Thomas S. Dye
2015-04-23 16:20       ` Rainer M Krug
2015-04-23 16:42         ` Aaron Ecay
2015-04-23 16:13     ` Charles C. Berry
2015-04-23 16:29       ` Rainer M Krug
2015-04-23 17:11         ` Thomas S. Dye
2015-04-23 22:39           ` Aaron Ecay [this message]
2015-04-23 23:36             ` Thomas S. Dye
2015-04-26 12:49         ` Nicolas Goaziou
2015-04-26 17:11           ` Charles C. Berry
2015-04-26 17:28             ` Nicolas Goaziou
2015-05-04  8:35             ` Rainer M Krug
2015-05-04 19:03               ` Nicolas Goaziou
2015-04-23  6:35   ` 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=87h9s65v0x.fsf@gmail.com \
    --to=aaronecay@gmail.com \
    --cc=ccberry@ucsd.edu \
    --cc=emacs-orgmode@gnu.org \
    --cc=r.m.krug@gmail.com \
    --cc=tsd@tsdye.com \
    /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).