# First Name First After First Author in apalike

I use apalike modified to show first names in references. This version works well, but I want to locate first names first for all authors after the first one. For example, I want to have Doe, John and Jane Doe rather than Doe, John and Doe, Jane in references. Can I change apalike's naming order for second and third authors? Here's the MWE.

\documentclass{article}
\begin{document}
\bibliographystyle{apalike}
\cite{asdf}
\bibliography{asdf}
\end{document}


And asdf.bib contains the following information.

@article{asdf,
title={asdf},
author={Doe, John and Doe, Jane},
journal={asdf},
volume={1},
number={1},
pages={1--2},
year={1111}
}


The relevant function to be changed in your modified .bst file is the function

FUNCTION {format.names}


which is on line 209 of the original .bst file. In your modified version of the you may have the following formatting schema which says put the full first name first last.

s nameptr "{vv~}{ll}{, jj}{, ff}" format.name$'t := % last name first  Change this to: s nameptr duplicate$ #1 >
{ "{ff~}{vv~}{ll}{, jj}" }
{ "{vv~}{ll}{, jj}{, ff}" }
if$format.name$ 't :=   % last name first


which will put full first name first on all non-initial names.

As with any modification to a .bst file, make sure you rename it and work on a copy of the original (which I assume from your question you are already doing.)

Here's a sample document with the changed .bst file.

\documentclass{article}
\begin{filecontents}{\jobname.bib}

@article{BerwickPietroskiYankama2011,
Author = {Robert Berwick and Paul Pietroski and Beracah Yankama and Noam Chomsky},
Journal = {Cognitive Science},
Pages = {1207-1242},
Title = {Poverty of the stimulus revisited},
Volume = {35},
Year = {2011}}

@article{Chomsky1977,
Author = {Noam Chomsky and Howard Lasnik},
Journal = {Linguistic Inquiry},
Pages = {425-504},
Title = {Filters and Control},
Volume = {8},
Year = {1977}}

@article{HauserChomskyFitch2002,
Author = {Hauser, Marc and Chomsky, Noam and Fitch, W. Tecumseh},
Journal = {Science},
Number = {5598},
Pages = {1569--1579},
Title = {The Faculty of Language: What Is It, Who Has It, and How Did It Evolve?},
Volume = {298},
Year = {2002}}
\end{filecontents}

\usepackage{natbib}
\bibliographystyle{apalike-lastname}
\begin{document}
\cite{BerwickPietroskiYankama2011,Chomsky1977,HauserChomskyFitch2002}
\bibliography{\jobname}
\end{document}


• Yes. I want to change the naming order in references. Aug 21 '20 at 7:28
• @Mico You're absolutely right, of course. I don't know what I was thinking with the original answer. I've fixed things properly now. Thanks. Aug 21 '20 at 12:56
• +1. Indeed, I'm always happy to upvote your postings. :-)
– Mico
Aug 21 '20 at 12:59
• Thanks. I got exactly what I wanted. I cannot fully understand the way your changed code works though—bst is harder than tex for me. Aug 21 '20 at 19:25
• @JunyongKim All I did was add a conditional which checks whether the current name being processed (represented by the nameptr variable) is the is the first one or not, and then either uses the {ff~}{vv~}{ll}{, jj} schema (if nameptr > 1) or the {vv~}{ll}{, jj}{, ff} schema (if nameptr = 1). Aug 21 '20 at 20:15