我正在使用ACM-Reference-Format。我需要根据它们在论文中出现的顺序对引用进行排序,因此我尝试使用biblatex
包,如下所示:
\usepackage[sorting=none]{biblatex}
\bibliographystyle{ACM-Reference-Format}
但后来我收到了以下错误:
我有什么遗漏的吗?谢谢!
答案 0 :(得分:3)
默认情况下,acm类启用natbib
,这与biblatex
不兼容。幸运的是,有一个选项可以关闭它。然后,您可以按如下方式使用biblatex
,包括sorting=none
选项:
\documentclass[sigconf,natbib=false]{acmart}
\usepackage[style=ACM-Reference-Format,backend=bibtex,sorting=none]{biblatex}
\addbibresource{sample-bibliography.bib}
并放
\printbibliography
当您想要打印文档时,在文档中的位置。
对sample-sigconf.tex
执行此操作并添加\nocite{*}
会导致参考书目从以下开始,将Lamport作为第一个参考,而不是以A开头的作者的文章。
这是一个证明这一点的最小文档:
\documentclass[sigconf,natbib=false]{acmart}
\usepackage[style=ACM-Reference-Format,backend=bibtex,sorting=none]{biblatex}
\addbibresource{sample-bibliography.bib}
\begin{document}
\title{Contribution title}
\author{A. N. Author}
\maketitle
\textcite{Kosiur01} and \textcite{Cohen07}
\printbibliography
\end{document}
sample-bibliography.bib
包含
@Article{Cohen07,
author = "Sarah Cohen and Werner Nutt and Yehoshua Sagic",
title = "Deciding equivalances among conjunctive aggregate queries",
journal = JACM,
articleno = "5",
numpages = "50",
volume = "54",
number = "2",
month = apr,
year = "2007",
doi = "10.1145/1219092.1219093",
url = "http://doi.acm.org/10.1145/1219092.1219093",
acmid = "1219093",
note = "",
}
@Book{Kosiur01,
author = "David Kosiur",
title = "Understanding Policy-Based Networking",
publisher = "Wiley",
year = "2001",
address = "New York, NY",
edition = "2nd.",
editor = "",
volume = "",
number = "",
series = "",
month = "",
note = "",
}
在pdflatex, bibtex, pdflatex, pdflatex
后给出:
删除sorting=none
选项导致参考书目中的顺序相反。
切换到默认后端biber
而不是bibtex
,您可以访问biblatex
的更多功能。