From: Dan Davison <davison@stats.ox.ac.uk>
To: Eric Schulte <schulte.eric@gmail.com>
Cc: Emacs-orgmode@gnu.org
Subject: [babel] Re: org-babel: Meta-LaTeX-Python-Environment
Date: Wed, 28 Oct 2009 12:10:04 -0400 [thread overview]
Message-ID: <87aazblctf.fsf_-_@stats.ox.ac.uk> (raw)
In-Reply-To: <m2k4yfwnp0.fsf@gmail.com> (Eric Schulte's message of "Wed, 28 Oct 2009 09:19:39 -0600")
Dear thread participants, please note that we were breaking the rule of
prepending the subject line with the string [babel]!
One question inline below.
"Eric Schulte" <schulte.eric@gmail.com> writes:
> "Thomas S. Dye" <tsd@tsdye.com> writes:
>
>> On Oct 27, 2009, at 12:55 PM, Eric Schulte wrote:
>
>>> Although I still don't fully understand the need to embed latex
>>> *inside*
>>> of source-code blocks, perhaps the attached org-babel-latex.el file
>>> [1]
>>> will represent a simpler solution for embedding the results of
>>> source-code blocks in latex source-code blocks. It makes use of
>>> the :var org-babel header argument as shown in the attached example
>>> file
>>> [2]. To reproduce first load org-babel-latex.el and then evaluate the
>>> latex block (note the results are already in the file from my test
>>> evaluation).
>>>
>>> Hope this helps -- Eric
>>>
>>> Footnotes:
>>> [1] <org-babel-latex.el>
>>> [2] <latex.org>
>>
>> Thanks for this, Eric. It looks neat. I was happy with all the
>> little .tex files, but agree with Torsten that this path is
>> potentially cleaner.
>>
>
> Please let me know if you do find this useful or have any suggestions.
> If it proves useful I will add it to the org-mode repository.
Am I right in thinking that one issue remaining in this thread is that
we currently have no means of tangling the output of org-babel-latex?
Thus the 'begin_src latex' blocks that we can tangle have unevaluated
variables, and the resulting 'begin_latex' blocks have evaluated
variables but can't be tangled? (We could extend tangling to cover such
blocks, or perhaps preferably use ':results code' to generate 'begin_src
latex' blocks?)
Dan
>
>>
>> In response to the implicit question in your comment, perhaps there
>> isn't a need to embed LaTeX inside source blocks and the uses to which
>> I put them could be accomplished in org-mode without them. My
>> programming skills are pretty crude and I'm aware that I'm a long way
>> from understanding org-mode and its vast potential. With that caveat,
>> here is my $0.02.
>>
>
> I'm also very far from taking full advantage of Org-mode export
>
>>
>> First, practical reasons:
>>
>> 1) I'm comfortable writing LaTeX and am particular about the results;
>> it is hard for me to map the inverse transformation through the org-
>> mode LaTeX exporter to express in org the particular LaTeX result I'm
>> after.
>>
>> 2) Someone on the list (Carsten?) mentioned a couple of days ago that
>> it wasn't reasonable to expect the org LaTeX exporter to capture the
>> full complexity of LaTeX (I'm paraphrasing, but I think that was the
>> gist); I ran up against an example of this (or so I think) when trying
>> to configure export to beamer code, where beamer's use of columns
>> tripped me up.
>>
>
> I fully understand your point. I guess that given my personal paucity
> of latex knowledge and abilities the same need has never occurred to
> me. In my case the Org-mode exported generally knows more about latex
> than I do.
>
>>
>> Second, conceptual reasons:
>>
>> 1) I consider writing LaTeX to be programming (here I mean no
>> disrespect to real programmers) and appreciate being able to do
>> literate LaTeX programming; the LaTeX source blocks let me write my
>> beamer presentation a slide or two at a time, just as I want them,
>> along with an adjacent source block for my print document, just as i
>> want it, that covers the same conceptual space, while I use the
>> surrounding org entries to document why I am doing things a particular
>> way, etc.
>>
>
> I see, you are using the org-mode file "a level above" the direct
> export. Maybe another option here would be to tag headlines based on
> which export target they are included within, and then base your exports
> on the headline tags (using #+EXPORT_INCLUDE_TAGS:), although I agree
> this also seems like an appropriate place to use the tangle
> functionality.
>
>>
>> 2) I think this workflow, with an org-mode meta-document that
>> encapsulates the print document and presentation materials, along with
>> the SQL, R, and Python code used to create the datasets and analyze
>> them, takes org-babel a step closer to realizing its potential as a
>> tool for reproducible research. Here, I am thinking of an org
>> document that captures the ways in which a piece of research is one
>> logical path among many possibilities, implemented and expressed in
>> one particular way (or two, if you want to distinguish print from
>> presentation) among many possibilities.
>>
>> The LaTeX source blocks in org-babel give me an easy and natural way
>> to accomplish these things. In the short time I've used them, they've
>> yielded results that impress me. I'm confident they hold much more
>> potential than I've been able to tap.
>>
>
> I didn't mean to imply that because I didn't understand the need for
> direct inclusion of latex code there *wasn't* a need for direct
> inclusion of latex code :) Thanks for the explanation.
>
>>
>> It is a real pleasure leveraging your good work.
>>
>
> It is a pleasure to be able to participate in such a nice open-source
> community. -- Eric
>
>>
>> Tom
>
>
> _______________________________________________
> Emacs-orgmode mailing list
> Remember: use `Reply All' to send replies to the list.
> Emacs-orgmode@gnu.org
> http://lists.gnu.org/mailman/listinfo/emacs-orgmode
next prev parent reply other threads:[~2009-10-28 16:10 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-10-26 4:27 org-babel: Meta-LaTeX-Python-Environment Torsten Wagner
2009-10-27 0:24 ` Dan Davison
2009-10-27 8:23 ` Thomas S. Dye
2009-10-27 14:57 ` Torsten Wagner
2009-10-27 22:55 ` Eric Schulte
2009-10-28 0:40 ` Thomas S. Dye
2009-10-28 15:19 ` Eric Schulte
2009-10-28 16:10 ` Dan Davison [this message]
2009-10-28 16:49 ` [babel] " Dan Davison
2009-10-28 16:52 ` Thomas S. Dye
2009-10-28 17:15 ` Eric Schulte
2009-10-28 18:46 ` Thomas S. Dye
2009-10-28 22:19 ` Eric Schulte
2009-10-29 6:55 ` Thomas S. Dye
2009-10-28 16:25 ` Thomas S. Dye
2009-10-27 13:29 ` Torsten Wagner
2009-10-29 15:52 ` [babel] Meta-LaTeX-Python-Environment Dan Davison
[not found] ` <4edb2bbc0910270625ybce9255nf569b5e250d061e1@mail.gmail.com>
2009-10-28 16:57 ` org-babel: Meta-LaTeX-Python-Environment Dan Davison
2009-10-29 4:52 ` [babel]org-babel: Meta-LaTeX-Python-Environment Torsten Wagner
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=87aazblctf.fsf_-_@stats.ox.ac.uk \
--to=davison@stats.ox.ac.uk \
--cc=Emacs-orgmode@gnu.org \
--cc=schulte.eric@gmail.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).