我使用Rstudio测试bookdown-chinese-master.zip模板的过程中出现错误
(同时也测试了bookdown-demo-master.zip英文模板, 错误相同)
Failed to build the bibliography via bibtex
Please delete bookdown.Rmd after you finish debugging the error.
然后我尝试将
citation_package: natbib
去掉或注释掉, 或者改为
citation_package: none
模板可以成功运行.
我想知道如何才能在bookdown中使用natbib?
我想既然是模板, 应该问题出在我的电脑上, 但我使用纯Latex测试natbib可以成功, 示例如下
\documentclass{book}
\usepackage{lipsum} % random text
\usepackage{natbib}
\begin{document}
\lipsum
\setcitestyle{numbers}
%\bibliographystyle{apalike}
%\bibliographystyle{plainnat}
\bibliographystyle{unsrtnat}
\nocite{*} % list all refs
\bibliography{packages.bib} % from bookdown-chinese-master.zip
\end{document}
不知道问题出在哪里?