1

I am trying to customize my bibliography to match the requirements of a journal, and by using makebst, I arrived at something that comes pretty close to what I need. However, makebst, while offering some options for the appearance of "volume" and "number" in journal articles, does not offer to have the two entries separated by a slash (like: "32/4"). Right now, it gives "volume" and "number" as "32(4)". Is there an easy way to fix that?

  • 2
    The journal asks you to provide a bst? Don't journals usually have their own templates ready? – Tiuri Aug 7 '17 at 10:22
  • Which journal style are you trying to replicate? – user36296 Aug 7 '17 at 10:54
  • Please show the contents of the function format.vol.num.pages that's in your bst file. – Mico Aug 7 '17 at 13:25
  • @Tiuri I asked them, they don't. – Janine Aug 8 '17 at 13:30
  • @samcarter The Philosophical Quarterly – Janine Aug 8 '17 at 13:31
2

You could use the biblatex package (I assume, you already do) and use \renewbibmacro (p. 203 biblatex manual) or \DeclareFieldFormat.

There is an example for code and output. If you read the manual and other Q&As like this one or this, I am sure, you'll be able to customize it exactly the way you want it.

\documentclass[A4]{scrartcl}%
\usepackage[%
style=authoryear,%
backend=biber,%
uniquename=false,% 
uniquelist=false,% 
doi=false,%
isbn=false,%
url=false,%
eprint=false,%
]{biblatex}%
\usepackage{csquotes}

\renewbibmacro*{volume+number+eid}{%
\printfield{volume}%
\setunit{\addnbthinspace\slash\addnbthinspace}%
\printfield{number}%
\setunit{\addcomma}%
\printfield{eid}}%

%\DeclareFieldFormat[article]{number}{\slash{#1}} %a second way to change the number field and its delimiters

\usepackage{filecontents}%
\begin{filecontents}{\jobname.bib}
@article{Name.2016,%
author = {Author, Name},%
year = {2016},%
title = {{National cross-sectional study of nothing}},%
pages = {543-548},%
pagination = {page},%
volume = {105},%
journaltitle = {Acta rediculanda},%
number = {11}%
}%
\end{filecontents}%

\addbibresource{\jobname.bib}%

\begin{document}%
\cite{Name.2016}%
\printbibliography[heading=bibintoc]%
\end{document}%

Output: Output with slash between number and issue

1

In the .bst, I changed the entry FUNCTION {format.vol.num.pages} to

FUNCTION {format.vol.num.pages}
{ volume field.or.null
  duplicate$ empty$ 'skip$
    {
      "volume" bibinfo.check
    }
  if$
  number "number" bibinfo.check duplicate$ empty$ 'skip$
    {
      swap$ duplicate$ empty$
        { "there's a number but no volume in " cite$ * warning$ }
        'skip$
      if$
      swap$
      "/" swap$ *
    }
  if$ *
}

That does it nicely.

  • 1
    It would have been helpful if you had posted the original BibTeX code as well. – Mico Aug 9 '17 at 9:25
  • Yes, I guess. Sorry! – Janine Aug 11 '17 at 8:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.