BibTeX, biblatex and biber ⇒ Number and linebreak between references in the bibliography
Number and linebreak between references in the bibliography
Hi there,
I need to format my reference list so that it has a number, separated by a linebreak between each reference (these are the guidelines of a particular journal):
1.
Begon, M., Harper, J. & Townsend, C. (1996). Ecology: Individuals, Populations and Communities. 3rd edn. Blackwell Science, Oxford.
2.
Ferris, C., King, R.A. & Gray, A.J. (1997). Molecular evidence for the maternal parentage in the hybrid origin of Spartina anglica C.E. Hubbard. Mol. Ecol., 6, 185-187.
3.
Milligan, B. (1992). Plant DNA isolation. In: Molecular Genetic Analysis of Populations: A Practical Approach (ed. Hoelzel, A.R.). IRL Press, Oxford, UK, pp. 59-88.
Using packages like natbib it is possible to number the reference list, but i haven't found any examples that allow me to put a linebreak between the number and the reference itself. Any ideas?
I need to format my reference list so that it has a number, separated by a linebreak between each reference (these are the guidelines of a particular journal):
1.
Begon, M., Harper, J. & Townsend, C. (1996). Ecology: Individuals, Populations and Communities. 3rd edn. Blackwell Science, Oxford.
2.
Ferris, C., King, R.A. & Gray, A.J. (1997). Molecular evidence for the maternal parentage in the hybrid origin of Spartina anglica C.E. Hubbard. Mol. Ecol., 6, 185-187.
3.
Milligan, B. (1992). Plant DNA isolation. In: Molecular Genetic Analysis of Populations: A Practical Approach (ed. Hoelzel, A.R.). IRL Press, Oxford, UK, pp. 59-88.
Using packages like natbib it is possible to number the reference list, but i haven't found any examples that allow me to put a linebreak between the number and the reference itself. Any ideas?
-
- Posts: 707
- Joined: Tue Mar 25, 2008 5:02 pm
Number and linebreak between references in the bibliography
The following is brute-force, but might work:
Code: Select all
\makeatletter
\def\@biblabel#1{#1.\\}
\makeatother
Re: Number and linebreak between references in the bibliogra
This works in that it puts a number by the reference, but it doesn't add the linebreak (which i guess us what the \\ is meant for). I've tried hacking my .bst file by putting newline$ at various points in different functions, but nothing seems to work.
Further help much appreciated!
Further help much appreciated!
Number and linebreak between references in the bibliography
Hi dtalmy,
Welcome to the LaTeX community!
In order to help us helping you please prepare a proper
minimal working example* so we can see how you create your bibliography.
Regards
*If you don't know what that is please follow the link!
Welcome to the LaTeX community!
In order to help us helping you please prepare a proper

Regards
*If you don't know what that is please follow the link!
site moderator & package author
-
- Posts: 707
- Joined: Tue Mar 25, 2008 5:02 pm
Number and linebreak between references in the bibliography
I think this will work: take your bibliography style file, and make a copy of it with a different name (this is actually REQUIRED if using a standard, copyrighted BST file, by the way). Find the line that says or something similar. Below that, there should be a line that is the empty string by itself. Change that empty string to
Please ignore my first post, then---that's what I get for posting without testing it first!
Code: Select all
"\bibitem{" write$
"\hspace{0em}\\"
and save the file. That file should now break the line right after the number.Please ignore my first post, then---that's what I get for posting without testing it first!
Last edited by cgnieder on Thu Oct 04, 2012 10:31 pm, edited 1 time in total.
Number and linebreak between references in the bibliography
I'm a little reluctant to provide a minimal working example because what i'm doing involves hacking a .bst file:
http://www.lecb.ncifcrf.gov/~toms/ftp/ecol_let.bst
I guess Kaiserkarl13 is saying the function that needs to be modified in order for me to get a number and line break before the first author is the following:
i've tried a few things but nothing seems to work
cheers,
David
http://www.lecb.ncifcrf.gov/~toms/ftp/ecol_let.bst
I guess Kaiserkarl13 is saying the function that needs to be modified in order for me to get a number and line break before the first author is the following:
Code: Select all
FUNCTION {output.bibitem}
{ newline$
"\bibitem[{" write$
label write$
")" make.full.names duplicate$ short.list =
{ pop$ }
{ * }
if$
"}]{" * write$
cite$ write$
"}" write$
newline$
""
before.all 'output.state :=
}
cheers,
David
-
- Posts: 707
- Joined: Tue Mar 25, 2008 5:02 pm
Number and linebreak between references in the bibliography
It worked for me:
The following is an example that, I think, will reproduce what you want to do:
Code: Select all
FUNCTION {output.bibitem}
{ newline$
"\bibitem[{" write$
label write$
")" make.full.names duplicate$ short.list =
{ pop$ }
{ * }
if$
"}]{" * write$
cite$ write$
"}" write$
newline$
"\hspace{0em}\\" % CHANGED LINE
before.all 'output.state :=
}
Code: Select all
\documentclass{article}
\usepackage[numbers]{natbib} % Your database assumes author-year; this overrides
\usepackage{url}
\makeatletter
\def\@biblabel#1{#1} % changes numbers from [1] to 1.
\makeatother
\begin{document}
\nocite{*}
\bibliographystyle{ecol_let.bst}
\bibliography{yourbibliographydatabasename}
\end{document}
Re: Number and linebreak between references in the bibliogra
I understand the part with the spacing and was able to change that. But I also want the reference list numbered BUT in the main text it should be author-year. How do I do that?
Re: Number and linebreak between references in the bibliogra
Hi Annek,
Did you eventually solve your problem? I am trying to submit to the same journal, and have the same problem...
Hope you can help me!
Did you eventually solve your problem? I am trying to submit to the same journal, and have the same problem...
Hope you can help me!