25

I'm trying to numerate the references list but having them ordered in order of appearance. I can't find how to do that anywhere.

The code is, more or less, like this

\usepackage[round, sort, numbers, authoryear]{natbib}
(...)
\bibliographystyle{unsrtnat}
\bibliography{referencias}
\end{document}

The document resulting of that code is close to what I wanted, but the references lists still not numbered. Here are some screenshots.

enter image description here

enter image description here

The thing is, I can set the references to use numbers or Harvard referencing style, but not both.

Is there any way to do this using natbib?

Hope you can understand what am I trying to do here and give me a piece of advice.

Thx a lot!

MWE

.tex

\documentclass{article}

\usepackage[round, sort, numbers, authoryear]{natbib}

\begin{document}
\section{First section}

First I'm going to cite \citep{DBLP:journals/chb/Junco12}. I also want you to read \citet{Kirschner20101237} and \citep*{Ross2009578}. Don't forget to tell me what do you think about them.

\bibliographystyle{unsrtnat}
\bibliography{mwe-ref}
\end{document}

.bib

@article{DBLP:journals/chb/Junco12,
  author    = {Reynol Junco},
  title     = {Too much face and not enough books: The relationship between
               multiple indices of Facebook use and academic performance},
  journal   = {Computers in Human Behavior},
  volume    = {28},
  number    = {1},
  year      = {2012},
  pages     = {187-198},
  ee        = {http://dx.doi.org/10.1016/j.chb.2011.08.026},
  bibsource = {DBLP, http://dblp.uni-trier.de}
}

@article{Ross2009578,
title = "Personality and motivations associated with Facebook use",
journal = "Computers in Human Behavior",
volume = "25",
number = "2",
pages = "578 - 586",
year = "2009",
url = "http://www.sciencedirect.com/science/article/pii/S0747563208002355",
author = "Craig Ross and Emily S. Orr and Mia Sisic and Jaime M. Arseneault and Mary G. Simmering and R. Robert Orr"}

@article{Kirschner20101237,
title = "Facebook and academic performance",
journal = "Computers in Human Behavior",
volume = "26",
number = "6",
pages = "1237 - 1245",
year = "2010",
issn = "0747-5632",
url = "http://www.sciencedirect.com/science/article/pii/S0747563210000646",
author = "Paul A. Kirschner and Aryn C. Karpinski"}
3
  • it works awesome! thx a lot, both of you :)
    – vkmc
    Commented Jul 19, 2012 at 23:47
  • Could you comment more on this? I have the same problem and cannot find a solution. So far, my solution has been: 1. Set natbib options to "numbers" and generate the BBL 2. Open the .bbl file and save as a .tex file (with some other name, e.g. fileBib.tex) 3. Use \input{fileBib} at the end of the source file instead of calling the .bib database 4. Re-compiling changing the natbib options to "authoryear". There MUST be an easier way...
    – user39277
    Commented Oct 31, 2013 at 23:30
  • Solution according a related question: use unsrtnat.
    – Trylks
    Commented Mar 17, 2014 at 15:45

4 Answers 4

8

I would drop authoryear from \usepackage[round, sort, numbers, authoryear]{natbib}

5
  • Thanks for ur reply, but it didn't make the difference. It just replaced the citations in the text with numbers, and numbered the references list. I want to keep the citations as Harvard style (Jones et al., etc)
    – vkmc
    Commented Jul 19, 2012 at 13:04
  • works! deleting all temporary files and adding \usepackage{hyperref} - thanks again!
    – vkmc
    Commented Jul 19, 2012 at 23:48
  • Great! I am happy to hear Commented Jul 20, 2012 at 3:44
  • 14
    I honestly don't see how this can work to produce the output requested.
    – Alan Munn
    Commented Oct 29, 2013 at 19:38
  • this does not solve the problem indeed.
    – enthu
    Commented Dec 8, 2019 at 10:58
0

Change \bibliographystyle to ieeer and just keep the option numbers when adding Natbib package.

4
  • nope: "I couldn't open style file ieeer.bst"
    – JHBonarius
    Commented Mar 18, 2018 at 13:01
  • Sorry for not making it clear. My point is to set your style to IEEER. Thus, the preamble should be \usepackage[numbers]{natbib} followed by \bibliographystyle{ieeer}
    – Cuong
    Commented Mar 21, 2018 at 2:50
  • 1
    Still doesn't work
    – rhody
    Commented Dec 17, 2019 at 17:07
  • It is ieeetr istead of ieeer Commented Mar 31, 2021 at 5:12
0

You can try to use it.

\usepackage[numbers]{natbib}


\bibliographystyle{ieeetr}
\bibliography{ref} 
0

For me with the NeurIPS template, which by default loads natbib

\bibliographystyle{unsrtnat}
\setcitestyle{square,numbers,comma}

works for me

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .