Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I'm using a modification of the plainyr BibTeX style. Although my bib-file contains all initials for some authors (e.g. B.D. McKay), I end up with just the first initial in my document (e.g. B. McKay). I thought about editing the BibTeX style myself, but after seeing the code, I decided against it. Maybe there are some people who are more knowledgeable in this area of expertise.

I want my final document to include the initials for all the names, and not just those of the first name.

This is the relevant code of the BibTeX style, or at least, I think it is the relevant code.

FUNCTION {format.names}
{ 's :=
  #1 'nameptr :=
  s num.names$ 'numnames :=
  numnames 'namesleft :=
    { namesleft #0 > }
    { s nameptr "{f.~}{vv~}{ll}{, jj}" format.name$ 't :=
      nameptr #1 >
        { namesleft #1 >
            { ", " * t * }
            { numnames #2 >
                { "," * }
                'skip$
              if$
              t "others" =
                { " et~al." * }
                { " and " * t * }
              if$
            }
          if$
        }
        't
      if$
      nameptr #1 + 'nameptr :=
      namesleft #1 - 'namesleft :=
    }
  while$
}
share|improve this question
1  
Do you have a space between the initials? BibTeX interprets B.D. as a single name, but B. D. as two initials. That is part of the format.name$ function, so you cannot alter this behaviour and must have it right in the database. –  Joseph Wright Jun 14 '12 at 8:35
    
Indeed, that fixes the problem. Thanks a bunch! –  nvcleemp Jun 14 '12 at 8:41
    
Btw, If you formulate that as an answer, I can mark it answered. –  nvcleemp Jun 14 '12 at 8:42

1 Answer 1

up vote 6 down vote accepted

The BibTeX format.name$ function interprets B.D. as a single name, but B. D. as two initials. Thus you must have a space between each initial for BibTeX to correctly produce more than one initial in the output. Editing the database is the only way to sort this out.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.