3

I'm currently using the apalike style for my bibliography, using natbib for author-year, however when I generate the bibliography I lose the labels that normally precede the reference,

i.e. [S. Rostami, 2010] Shahin Rostami (2010) https://stackoverflow.com/questions/ask etc etc..

I read apalike.bst and it seems this is intended, my quesiton is, how do I get them back? Something I can include in the preamble? Otherwise is there a similar style that shows labels?

Also, I'm doing this all in Lyx.

Community
  • 1
  • 1
asleep
  • 4,054
  • 10
  • 34
  • 51
  • Do you mean you want the ref. to appear as in your example, with the author and the year shown *twice*? – AVB Apr 01 '10 at 20:30
  • APA style does *not* repeat author/year in this way, nor does any major author-date style. Why are you using apalike, and why do you want to do this? The "alpha" style does show labels. – Charles Stewart Apr 02 '10 at 09:40
  • I've left this reply a few times but it won't post. "The only reason is because my university guidelines recommend it" – asleep Apr 05 '10 at 12:28
  • 1
    @Charles Stewart: yes, but for example if there were more than 3 authors the ref. will be [S. Rostami et al] Shahin Rostami, Charles Stewart, John Derekson, Blah blah – asleep Apr 07 '10 at 21:10
  • 1
    @Shahin: Looking up citations with et al. in the reference list isn't difficult, at least for experienced article navigators. FWIW, in APA style, the first citation would list all authors if there were between 3 and 5 authors, with only subsequent citations being shortened to one author plus "et al.". Also, you omit the initial in APA citations. I advise against using a homebrew citation style in an article aimed at a scientific audience. – Charles Stewart Apr 08 '10 at 06:23
  • @Charles Stewart: Thanks for the response, I agree with you entirely and I would set this as the correct answer but it seems all I can do is vote it up as a comment! If you submit it as an Answer I'll mark it. – asleep Apr 08 '10 at 20:25

1 Answers1

2

OK, a real answer!

Advice: don't use homebrew citation styles in scientific articles. If your university recommends a specific style (e.g., APA, Chicago), use the existing matching style. Otherwise, you can get a feel for what is the dominant citation/reflist style by looking at what styles used by the articles you cite.

If you really do want to create such a homebrew cite/reflist style, then the easy option is to copy the .bbl file into your article and edit that: with luck, you can devise a regex that will create all or most of the labels you want. But rerunning Bibtex will not respect the changes you have made. The "right" thing is to clone apalike.bst and change the way it generates the author/date sentence to include the label information as well. BST hacking is a bit of a black art —time-consuming, fiddly, and poorly documented— but the language is not essentially difficult. Look at btxhak, Designing Bibtex styles and Nicolas Markey's tutorial to get started. Alternatively, there are some bst-hackery-avoiding suggestions in this SO Q&A.

Community
  • 1
  • 1
Charles Stewart
  • 11,661
  • 4
  • 46
  • 85