Eda*_*ame 4 latex bibtex bibliography biblatex
我正在使用ACM参考格式。我需要根据引用在论文中出现的顺序对引用进行排序,因此我尝试使用biblatex如下包装:
\usepackage[sorting=none]{biblatex}
\bibliographystyle{ACM-Reference-Format}
Run Code Online (Sandbox Code Playgroud)
但是然后我得到了以下错误:
我有什么想念的吗?谢谢!
默认情况下,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}
Run Code Online (Sandbox Code Playgroud)
并把
\printbibliography
Run Code Online (Sandbox Code Playgroud)
要在文档上要打印文档的位置。
这样做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}
Run Code Online (Sandbox Code Playgroud)
哪里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 = "",
}
Run Code Online (Sandbox Code Playgroud)
给予之后pdflatex, bibtex, pdflatex, pdflatex:
删除sorting=none选项将导致书目中的顺序相反。
切换到默认后端,biber而不是,bibtex您将可以使用的更多功能biblatex。