28 Dec 2010 18:53
Combining sweave and pdflatex into one helper function
Dirk Eddelbuettel <edd <at> debian.org>
2010-12-28 17:53:48 GMT
2010-12-28 17:53:48 GMT
Hi all,
I feel a little sheepish because it took me more than half a decade to find M-n
s and M-n P. But now that I found these new friends, I don't want to let go.
Better still, I would actually like to combine them both into a helper function
that runs them, additionally prefers pdflatex over texi2dvi and also tells the
pdf viewer to get lost as pdf viewers have been happy to refresh automagically.
At least on the OS I run most often, but I digress.
Now, I have what is not even read-only access to elisp so my lame attempt
(defun edd-sweave ()
"Run sweave and pdflatex"
(interactice)
(ess-swv-run-in-R "Sweave")
(ess-swv-latex)
(ess-swv-PDF "pdflatex")
)
(define-key noweb-minor-mode-map "\M-np" 'edd-sweave)
evaluates but does not make it into the Rnw buffer I currently have.
Could some kind soul help me out? CC to my address appreciated; I am not
subscribed here.
Also, if ESS Core could amend the behaviour of the ess-swv-PDF function, it
would already help a great deal. I cheat by defining /bin/true as my previewer
(Continue reading)
RSS Feed