![删除 .bst 文件中两个字段(机构和系列)之间的逗号](https://linux22.com/image/336847/%E5%88%A0%E9%99%A4%20.bst%20%E6%96%87%E4%BB%B6%E4%B8%AD%E4%B8%A4%E4%B8%AA%E5%AD%97%E6%AE%B5%EF%BC%88%E6%9C%BA%E6%9E%84%E5%92%8C%E7%B3%BB%E5%88%97%EF%BC%89%E4%B9%8B%E9%97%B4%E7%9A%84%E9%80%97%E5%8F%B7.png)
我正在尝试将类型unpublished
为 (工作论文) 的 bibtex 条目格式化为 类型article
。也就是说,机构 + 系列应格式化为期刊名称。
这是我的 bibtex 条目:
@unpublished{SomeKey,
title = {bst files are difficult},
year = {2015},
author = {Author, Unknown},
series = {Discussion Paper},
institution = {Bibtex-Institute}
}
为此,我正在调整agsm
风格:
FUNCTION {unpublished}
{ output.bibitem
list.label.output
" \harvardyearleft " list.year * "\harvardyearright " * output.nonnull
author "author" item.check
title.field field.used =
{ skip$ }
{ format.title quote "title" output.check }
if$
institution emphasize output
series emphasize output
new.block
fin.entry
}
输出
作者,U.(2015),“bst 文件很难”,Bibtex 学院,讨论文件。如何去掉字段 Institution 和 Series 之间的逗号?
原来的功能是:
FUNCTION {unpublished}
{ output.bibitem
list.label.output
" \harvardyearleft " list.year * "\harvardyearright " * output.nonnull
author "author" item.check
title.field field.used =
{ skip$ }
{ format.title "title" output.check }
if$
new.block
note "note" output.check
fin.entry
write.url
}
答案1
agsm.bst
我不会修改参考书目样式文件,而是使用类型为或 的note
字段。使用哪种类型取决于您是否希望将出版物的标题括在单引号中。@unpublished
@misc
哦,如果字符串Bibtex-Institute Discussion Paper
应该用斜体排版,只需替换
note = {Bibtex-Institute Discussion Paper},
和
note = {\emph{Bibtex-Institute Discussion Paper}},
\RequirePackage{filecontents}
\begin{filecontents}{mybib.bib}
@unpublished{SomeKeyA,
title = {bst files are difficult},
year = {2015},
author= {Author, Unknown},
note = {Bibtex-Institute Discussion Paper},
}
@misc{SomeKeyB,
title = {bst files are difficult},
year = {2016},
author= {Author, Unknown},
note = {Bibtex-Institute Discussion Paper},
}
\end{filecontents}
\documentclass{article}
\usepackage{har2nat}
\bibliographystyle{agsm}
\begin{document}