使用 biblatex.sty 删除末尾的 perid 并将其放在“(引用于第...页)”之前

使用 biblatex.sty 删除末尾的 perid 并将其放在“(引用于第...页)”之前

我的标签是:

\documentclass{book}

\usepackage{csquotes}
\usepackage[style=numeric,citestyle=numeric,sorting=nyt,sortcites=true,autopunct=true,autolang=hyphen,hyperref=true,abbreviate=false,backref=true,backend=biber]{biblatex}
% BibTeX bibliography file
\makeatletter
\defbibheading{bibempty}{}
\setlength{\bibhang}{5\p@}%
\setlength{\bibitemsep}{3\p@}%
\def\bibfont{\fontsize{8}{9}\selectfont}%
\renewcommand{\RNfont}{}
\makeatother

\usepackage{filecontents}
\begin{filecontents*}{\jobname.bib}
@inproceedings{acerbi2017practical,
  title     = {Practical Bayesian optimization for model fitting with Bayesian adaptive direct search},
  author    = {Acerbi, Luigi and Ma, Wei Ji},
  booktitle = {Proceedings of the 31st International Conference on Neural Information Processing Systems},
  pages     = {1834--1844},
  year      = {2017},
}

@article{acerbi2014origins,
  title={On the Origins of Suboptimality in Human Probabilistic Inference},
  author={Acerbi, Luigi and Vijayakumar, Sethu and Wolpert, Daniel M.},
  journal={PLoS Computational Biology},
  volume={10},
  number={6},
  pages={e1003661},
  year={2014},
  publisher={Public Library of Science San Francisco, USA}
}
@book{lucretius2007nature,
  title={The Nature of Things},
  author={Lucretius [Titus Lucretius Carus]},
  year={2007},
  publisher={Translated by A. E. Stallings. London: Penguin}
}
}

\end{filecontents*}

\addbibresource{\jobname.bib} 

%\DefineBibliographyStrings{english}{%
%  backrefpage = {test},
%  backrefpages= {test},
%}
\DeclareFieldFormat[inproceedings, incollection, unpublished]{pages}{#1} % no word 'pages' for articles in the bibliography (print as is)

\begin{document}

\renewcommand*{\intitlepunct}{%
  \ifentrytype{inproceedings}
    {\addspace}
    {\addcolon\space}}

%\renewcommand*{\intitlepunct}{%
%  \ifentrytype{article}
%    {\addspace}
%    {\addspace}}

%%\renewbibmacro*{in:}{%
%%  \setunit{\addcomma\space}%
%%  \ifentrytype{article}
%%    {}
%%    {\printtext{%
%%       \bibstring{In}\intitlepunct}}}
%\renewbibmacro*{in:}{%
%\ifentrytype{article}{}{\printtext{\intitlepunct}}
%  \bibstring{in}%
%  \printunit{\intitlepunct}}

\DeclareFieldFormat[incollection]{title}{\enquote{#1}}

\renewbibmacro*{in:}{%
  \setunit{\addcomma\space}%
  \ifentrytype{article}
    {}
    {\printtext{%
       \bibstring{In}\intitlepunct}}}

%\renewcommand*{\intitlepunct}{\addspace}

\cite{acerbi2017practical} and \cite{acerbi2014origins} and \cite{lucretius2007nature}

\clearpage

\printbibliography

\end{document}

产生的输出为:

在此处输入图片描述

我需要删除period之后的部分(cited on page...).并放置period之前的部分(cited...),例如输出应该是1834--1844. (cited on page 1)

我尝试使用backrefpage命令,但无法成功,请指教

非常感谢moewe他对...的大力支持biblatexbiblatex-chicago支持。

答案1

我们可以使用如何在参考书目中每一项末尾的句号后添加 biblatex backref

\documentclass{article}

\usepackage{csquotes}
\usepackage[
  backend=biber,
  style=numeric,
  sorting=nyt,
  sortcites=true,
  autopunct=true,
  autolang=hyphen,
  abbreviate=false,
  backref=true,
]{biblatex}

\renewcommand*{\bibpagerefpunct}{%
  \finentrypunct\space}

\renewbibmacro*{pageref}{%
  \iflistundef{pageref}
    {}
    {\printtext[parens]{%
       \ifnumgreater{\value{pageref}}{1}
         {\bibncpstring{backrefpages}\ppspace}
         {\bibncpstring{backrefpage}\ppspace}%
       \printlist[pageref][-\value{listtotal}]{pageref}}%
     \renewcommand*{\finentrypunct}{}}}

\begin{filecontents*}{\jobname.bib}
@inproceedings{acerbi2017practical,
  title     = {Practical Bayesian optimization for model fitting with Bayesian adaptive direct search},
  author    = {Acerbi, Luigi and Ma, Wei Ji},
  booktitle = {Proceedings of the 31st International Conference on Neural Information Processing Systems},
  pages     = {1834--1844},
  year      = {2017},
}
@article{acerbi2014origins,
  title     = {On the Origins of Suboptimality in Human Probabilistic Inference},
  author    = {Acerbi, Luigi and Vijayakumar, Sethu and Wolpert, Daniel M.},
  journal   = {PLoS Computational Biology},
  volume    = {10},
  number    = {6},
  pages     = {e1003661},
  year      = {2014},
  publisher = {Public Library of Science San Francisco, USA}
}
@book{lucretius2007nature,
  title     = {The Nature of Things},
  author    = {Lucretius [Titus Lucretius Carus]},
  year      = {2007},
  publisher = {Translated by A. E. Stallings. London: Penguin}
}
\end{filecontents*}
\addbibresource{\jobname.bib}

\begin{document}
\cite{acerbi2017practical} and \cite{acerbi2014origins} and \cite{lucretius2007nature}

\printbibliography
\end{document}

Luigi Acerbi 和 Wei Ji Ma。“使用贝叶斯自适应直接搜索进行模型拟合的实用贝叶斯优化”。刊于:第 31 届国际神经信息处理系统会议论文集。2017 年,第 1834-1844 页。(第 1 页引用)

答案2

通过使用以下标签:

\DefineBibliographyStrings{english}{%
  backrefpage = {\protect\lowercase{cited on page}},
  backrefpages= {\protect\lowercase{cited on pages}},
}

\def\fullstop{.}
\renewcommand*{\bibpagerefpunct}{\fullstop\space}
\renewcommand*{\finentrypunct}{}

我得到了所需的输出,其内容为:

在此处输入图片描述

但是,请专家(如moewe,,egreg以及其他许多人)确认这是正确的方法吗?

相关内容