2

I am curently using emacs with ESS, Auxtex, R and knitr. I would like to be able to cite from my bibliography in my child documents.

My master.Rnw looks rougly as follows:

\documentclass{article}

\input{preamble.tex} % with \addbibliography in it

\begin{document}

<<child_1>>=
knit_child("./functions.Rnw")
@

<<child_2>>=
knit_child("./models.Rnw")
@

\end{document}

I can knit the document with Meta-n r and I can also run Meta-n P (as described in the first answer here: ESS/AucTeX/Sweave integration.

Afterwards I can use my bibliography, which I indluded in my preambel.tex for citations in my master.Rnw.
If I try to access my bibliography in a child document with C-c [ I get the error message "no valid bibliography in this document and no default avalailable"

Running Meta-n P in a child document fails with "Undefined control sequence \section"

Any ideas would be really appreciated.

Community
  • 1
  • 1
  • I found it out myself. Simply add a default bibliography in your init.el instead of adding the bibliography in your praembel.tex. If you do not know how to do this, take a look at the first answer here http://tex.stackexchange.com/questions/54739/reftex-wont-find-my-bib-file-in-local-library-tree Hope this helps someone – Karl Müller Aug 01 '15 at 16:55

0 Answers0