emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Tag individual output lines from source block?
@ 2012-01-26  2:47 Michael Hannon
  0 siblings, 0 replies; only message in thread
From: Michael Hannon @ 2012-01-26  2:47 UTC (permalink / raw)
  To: emacs-orgmode

Greetings.  I'd like to know if there is some way to "tag" the output of a
source-code block so as to indicate which line of the source-code block
produced the output.

In the appended example, the results of computing both "myMat" and
"diag(myMat)" are juxtaposed.  I'm looking for a way to indicate that the
first part of the output is from "myMat", and the second is from
"diag(myMat)".

I understand that I could achieve the effect by using separate source-code
blocks and/or just inserting print statements into the source-code block.  I
just thought that there might be some Org-mode feature that I've overlooked.
(And, of course, the situation is not always as simple as in this example.)

Thanks,

-- Mike

#+PROPERTY: session *R*
#+PROPERTY: cache yes
#+PROPERTY: results output verbatim
#+PROPERTY: exports both
#+PROPERTY: tangle yes

* Test

#+BEGIN_SRC R

  myMat <- matrix(c(1, 2, 3, 4, 5, 6, 7, 8, 9), nrow=3)
  myMat
  
  diag(myMat)
  
#+END_SRC

#+RESULTS[3ac776362ed92ae4090c997f1b7b1922ee565681]:
:      [,1] [,2] [,3]
: [1,]    1    4    7
: [2,]    2    5    8
: [3,]    3    6    9
: [1] 1 5 9


Org-mode version 7.8.03 (release_7.8.03.237.g674bb)

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2012-01-26  2:48 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-01-26  2:47 Tag individual output lines from source block? Michael Hannon

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