3

To meet a journal's requirements I'd like to tweak my current bibliography in a REVTeX4.1 document to:

  1. Put parentheses around my (superscripted) citations so they read (1), (4), and (2,3,5) rather than 1, 4, and 2,3,5.

  2. Put parentheses around each numbered reference in the bibliography so they all read similar to (12) rather than 12. If possible, the bibliography list should be non-superscript while the in-text citations are superscript (not my rules... journal's request).

My MWE is as follows:

\documentclass[a4paper,twocolumn,       %   A4 paper, two columns
  nofootinbib,superscriptaddress,       %       
  aps,prb,citeautoscript, 10pt,         %   The prb style of RevTex uses superscript cross-references for citations
  eqsecnum,notitlepage,showkeys]{revtex4-1}

\usepackage{hyperref}   % Hyperref likes to be the last package included but putting it last breaks figure references!
\begin{document}
The manuscript elements have been formatted for you with LaTeX. 
References can be included such as \cite{R2006} or \cite{R2009}.
Multiple references are also handled \cite{R2007, R2002,CDCgirlGrowthCharts}.
\bibliographystyle{PAPER_IJAE_BIBTEX_plain}
\bibliography{PAPER_JSAE_template_BIBLIOGRAPHY}
\end{document}

With PAPER_JSAE_template_BIBLIOGRAPHY.bib containing:

@Article{R2007,
   Author="Another, J.  and van Alphabet, B.  and Master, M. A. ",
   Title="{{A}utomatic data is nice}",
   Journal="Med Image",
   Year="2007",
   Volume="11",
   Number="1",
   Pages="35--46",
   Month="Feb"
}
@mastersthesis{R2009,
    author    = "Matthew W. Author",
    title     = "Paper title here",
    school    = "University of Virginia",
    type     = "Master's thesis",
    address  = "",
    year      = "2007",
    month    = "",
    note     = "",
}
@online{CDCgirlGrowthCharts,
  author = {{National Center for Health Statistics}},
  title = {{CDC} Clinical Growth Charts},
  year = 2000,
  url = {http://www.cdc.gov/growthcharts/clinical_charts.htm},
  urldate = {30/09/2010}
  howpublished = {\url{http://www.cdc.gov/growthcharts/clinical_charts.htm}} 
}
@article{R2006,
   author = {Rabbit, Peter F  and Brown, J Charlie and Duck, Donald R},
   title = {Factors of growth},
   journal = {Journal of Surgery},
   volume = {41},
   number = {11},
   pages = {1854-1858},
   year = {2006}
}
@inproceedings{R2002,
   author = {Kane, M. and Freed, Y.},
   title = {Development for safety ({THUMS})},
   booktitle = {Proceedings of conference},
   year = {2002}
}

And my PAPER_IJAE_BIBTEX_plain.bst is really just a copy of plain.bst with a little tweak for formatting names - nothing that would affect the numbering (link to file here). I'm happy to make further changes to the .bst file, I just can't seem to narrow down the bit that affects what I'm trying to change. Any help appreciated.

Showing un-parenthesised cites-bibs

3

You can do this by redefining \NAT@biblabelnum and \NAT@citesuper (revtex4-1 internally uses natbib):

\documentclass[a4paper,twocolumn,
  nofootinbib,superscriptaddress,  
  aps,prb,citeautoscript, 10pt,
  eqsecnum,notitlepage,showkeys]{revtex4-1}
\usepackage{filecontents}% just for the example
\usepackage{hyperref} 

\begin{filecontents*}{PAPER_JSAE_template_BIBLIOGRAPHY.bib}
@Article{R2007,
   Author="Another, J.  and van Alphabet, B.  and Master, M. A. ",
   Title="{{A}utomatic data is nice}",
   Journal="Med Image",
   Year="2007",
   Volume="11",
   Number="1",
   Pages="35--46",
   Month="Feb"
}
@mastersthesis{R2009,
    author    = "Matthew W. Author",
    title     = "Paper title here",
    school    = "University of Virginia",
    type     = "Master's thesis",
    address  = "",
    year      = "2007",
    month    = "",
    note     = "",
}
@online{CDCgirlGrowthCharts,
  author = {{National Center for Health Statistics}},
  title = {{CDC} Clinical Growth Charts},
  year = 2000,
  url = {http://www.cdc.gov/growthcharts/clinical_charts.htm},
  urldate = {30/09/2010}
}
@article{R2006,
   author = {Rabbit, Peter F  and Brown, J Charlie and Duck, Donald R},
   title = {Factors of growth},
   journal = {Journal of Surgery},
   volume = {41},
   number = {11},
   pages = {1854-1858},
   year = {2006}
}
@inproceedings{R2002,
   author = {Kane, M. and Freed, Y.},
   title = {Development for safety ({THUMS})},
   booktitle = {Proceedings of conference},
   year = {2002}
}
\end{filecontents*}
\makeatletter
\renewcommand\NAT@biblabelnum[1]{\textsuperscript{(#1)}}
\renewcommand\NAT@citesuper[3]{\ifNAT@swa
\unskip\hspace{1\p@}\textsuperscript{(#1)}%
   \if\relax#3\relax\else\ (#3)\fi\else (#1)\fi\endgroup}
\makeatother

\begin{document}

The manuscript elements have been formatted for you with LaTeX. 
References can be included such as \citealp{R2006} or \citep{R2009}.
Multiple references are also handled \cite{R2007, R2002,CDCgirlGrowthCharts}.
\bibliographystyle{PAPER_IJAE_BIBTEX_plain}
\bibliography{PAPER_JSAE_template_BIBLIOGRAPHY}

\end{document}

enter image description here

  • Thanks Gonzalo, that worked perfectly for the in-text citations, but my bibliography still doesn't become parenthesised. I get the same result with/without the line: \renewcommand\@biblabel[1]{\textsuperscript{(#1)}} I'm using TeXworks and compiling pdfLaTeX+MakeIndex+BibTex. I've tried compiling just BibTex first as I've noticed changes in the bibliography need 2 compiles to make it through, but no luck yet. Can you help troubleshoot this? – sven Feb 16 '14 at 2:12
  • 1
    @sven Please see my updated answer. – Gonzalo Medina Feb 16 '14 at 2:37
  • Ah... got it - just a missing "NAT". Thanks muchly. – sven Feb 16 '14 at 3:21

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.