My citation for bibliography appear unsorted in the text like [6,3,4] instead of [3,4,6]. How can I make the appear sorted. I don't care how they appear at the end where they are all listed but my worry is for the appearance in the text. I have tried unsrt style but it does not make any difference. I am using \bibliographystyle{ieeetr}. Tash
-
Please post a Minimal (non-)Working Example of code which people can compile to reproduce your issue and test solutions. This greatly increases the chances of your receiving effective, timely responses by helping people to help you.– cfrMar 9, 2014 at 20:07
2 Answers
Since you're using a numeric citation style and haven't indicated that you're using a citation management package such as natbib
, you could get the citation numbers sorted by loading the cite
package:
\usepackage{cite}
-
Thank Mico, this worked perfectly. I also used notoccite package to fix the order. Great.– TashMar 10, 2014 at 16:36
If you use biblatex, you can choose a numeric style, for instance, and obtain what you want with this line in your preamble:
\usepackage[style=numeric,sortcites=true]{biblatex}
The sortcites=true
option makes the citations be sorted as in the bibliography.