From: Uwe Brauer <oub@mat.ucm.es>
To: emacs-orgmode@gnu.org
Subject: exporting org to latex, execute matlab before exporting
Date: Wed, 02 Aug 2017 12:08:16 +0000 [thread overview]
Message-ID: <87poce6ukv.fsf@mat.ucm.es> (raw)
Hello
Take the following example
* Test section
This is a test
#+begin_src matlab :results output latex :exports results
X=[1,2,3,4,5,6,7];
p=[1/7 1/7 1/7 1/7 1/7 1/7 1/7];
E=X*p';
x2=X.*X;
E2=x2*p';
V=E2-E^2;
disp('\begin{align}')
fprintf('E[X]&=%g\\\\ \n', E)
fprintf('E^2[X]&=%g\\\\\n', E2)
fprintf('V[X]&=%g\n', V)
disp('\end{align}')
#+end_src
Executing the src block leads
#+RESULTS:
#+BEGIN_EXPORT latex
\begin{align}
E[X]&=4\\
E^2[X]&=20\\
V[X]&=4
\end{align}
#+END_EXPORT
Which is what I want. When I convert the org file to latex I am again
asked to execute the src block, which I don't want since it is already
executed. How can I avoid this question, without deleting the src block.
This is important if I have a lot of blocks which I already have
executed, and want to export the file without denying is executing every
time I am asked.
Thanks
Uwe Brauer
next reply other threads:[~2017-08-02 12:08 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-08-02 12:08 Uwe Brauer [this message]
2017-08-03 7:42 ` [SOLVED] (was: exporting org to latex, execute matlab before exporting) Uwe Brauer
2017-08-03 8:04 ` [NOT SOLVED: BUG?] (was: [SOLVED]) Uwe Brauer
2017-08-03 16:40 ` Berry, Charles
2017-08-03 19:19 ` [NOT SOLVED: BUG?] Uwe Brauer
2017-08-06 21:04 ` exporting org to latex, execute matlab before exporting Grant Rettke
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=87poce6ukv.fsf@mat.ucm.es \
--to=oub@mat.ucm.es \
--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).