我嘗試使用單獨的參考文獻文件來引用兩種類型:學術(文章、期刊等)和非學術(網站、部落格等)。
為了將它們分開,我創建了一個文件Academic.bib
:
@article{academic,
journal = "Journal",
title = "Title",
author = "Author",
year = "2014"
}
還有另一個文件Non-academic.bib
:
@article{nonacademic,
journal = "Journal",
title = "Title",
author = "Author",
year = "2014"
}
但是,如果我嘗試在文件中引用它們,bibtex 會給我錯誤
"Illegal, another \bibdata command".
這是一個最小的例子:
\documentclass[a4paper,12pt,abstracton,titlepage]{scrartcl}
\usepackage{scrpage2}
\usepackage[utf8]{inputenc}
\title{Test document}
\author{Me}
\begin{document}
\maketitle
\newpage
\tableofcontents
\clearpage
\cite{academic} \cite{nonacademic}
\appendix
\section{Bibliography}
\label{sec:bibliography}
\bibliographystyle{plain}
\subsection{Academic}
\bibliography{Academic}{}
\bibliography{Academic,Non-academic}{}
\subsection{Non-Academic}
\bibliography{Non-academic}{}
\end{document}
我怎樣才能達到預期的結果?
答案1
Bibtex解決方案:
標準 bibtex 不可能提供多個參考書目。但是,該multibib
軟體包允許這樣做。
multibib
提供將\newcites{ac}{Academic}
代理人附加ac
到標準參考書目命令的命令,即\citeac
、\nociteac
和。第二個參數是參考書目的標題。在這種情況下需要第二個,即\bibliographystyleac
\bibliographyac
\newcites
\newcites{nac}{Non-academic}
跑完後,一人一人latex
跑 ;在這種情況下:bibtex
\newcites
bibtex ac
bibtex nac
然後再乳膠兩次。
這是一個完整的 MWE:
\documentclass[a4paper,12pt,abstracton,titlepage]{scrartcl}
\usepackage{scrpage2}
\usepackage{multibib}
\usepackage[utf8]{inputenc}
\newcites{ac}{Academic}
\newcites{nac}{Non-Academic}
\title{Test document}
\author{Me}
\begin{document}
\maketitle
\newpage
\tableofcontents
\clearpage
\
\citeac{academic} \citenac{nonacademic}
\appendix
\section{Bibliography}
\label{sec:bibliography}
\bibliographystyleac{plain}
\bibliographyac{Academic}{}
\bibliographystylenac{plain}
\bibliographynac{Non-academic}{}
\end{document}
生產:
比布拉泰克斯解決方案
biblatex 允許多個參考書目。在這種情況下,可以non
為非學術書目條目定義一個特殊類別,然後使用category
和notcategory
選項\printbibliography
\documentclass[a4paper,12pt,abstracton,titlepage]{scrartcl}
\usepackage{scrpage2}
\usepackage{biblatex}
\addbibresource{Academic.bib}
\addbibresource{Non-academic.bib}
\DeclareBibliographyCategory{non}
\addtocategory{non}{nonacademic}
\usepackage[utf8]{inputenc}
\title{Test document}
\author{Me}
\begin{document}
\maketitle
\newpage
\tableofcontents
\clearpage
\
\cite{academic} \cite{nonacademic}
\appendix
\section{Bibliography}
\label{sec:bibliography}
\printbibliography[title=Academic,heading=subbibliography,notcategory=non]
\printbibliography[title={Non-Academic},heading=subbibliography,category=non]
\end{document}