emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Omitting try/catch blocks from tangled R code?
@ 2014-02-07  6:18 John Hendy
  2014-02-07  8:26 ` [BABEL] BUG " Rainer M Krug
  0 siblings, 1 reply; 25+ messages in thread
From: John Hendy @ 2014-02-07  6:18 UTC (permalink / raw)
  To: emacs-orgmode

Greetings,


I don't usually tangle, but am creating a code file to go along with a
presentation I'm giving this weekend so that attendees can try things
out afterward by cloning my github repo where all the data and
necessary files are stored.

In my presentation (Beamer), I create plots via the R pdf() device,
and noticed that all of the tangled code where plots are generated
contains the following:

pdf(file="file.pdf"); tryCatch({

  code block contents here

},error=function(e){plot(x=-1:1, y=-1:1, type='n', xlab='', ylab='',
axes=FALSE); text(x=0, y=0, labels=e$message, col='red');
paste('ERROR', e$message, sep=' : ')}); dev.off()

Is there a way to omit this?

I'm guessing this is here to create a blank plot with the error as the
output when something goes awry?

I checked around variable completions of org-babel-tangle-* and
searched google for terms like "org babel tangle try catch" but am not
finding anything that looks like what I need.


Thanks,
John

^ permalink raw reply	[flat|nested] 25+ messages in thread

end of thread, other threads:[~2014-04-11  2:36 UTC | newest]

Thread overview: 25+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-02-07  6:18 Omitting try/catch blocks from tangled R code? John Hendy
2014-02-07  8:26 ` [BABEL] BUG " Rainer M Krug
2014-02-07 16:47   ` Eric Schulte
2014-02-07 19:22     ` Rainer M Krug
2014-03-12  1:13       ` John Hendy
2014-03-17 15:00         ` Eric Schulte
2014-03-17 17:11           ` John Hendy
2014-03-17 17:44             ` Eric Schulte
2014-03-18  8:44               ` Rainer M Krug
2014-03-18 21:56                 ` John Hendy
2014-03-19 19:07                   ` Charles Berry
2014-03-20  4:57                     ` Eric Schulte
2014-03-20  9:22                       ` Rainer M Krug
2014-03-24  2:03                         ` Eric Schulte
2014-03-24 10:22                           ` Rainer M Krug
2014-03-24 13:16                             ` Eric Schulte
2014-03-25  9:37                               ` Rainer M Krug
2014-03-26 20:17                                 ` Eric Schulte
2014-03-28  8:32                                   ` Rainer M Krug
2014-03-28  8:51                                   ` Rainer M Krug
2014-03-30 14:19                                     ` Eric Schulte
2014-03-31  7:52                                       ` Rainer M Krug
2014-04-02 23:09                                         ` Eric Schulte
2014-04-07  7:59                                           ` Rainer M Krug
2014-04-11  2:35                                             ` Eric Schulte

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).