In relation to the comments I want to provide an approach using biblatex
.
First of all I changed the definition of the output of authors and replace the name stored in \highlightname
with the initials saved in the macro \shortform
.
The main idea is inspired by P. Lehmann.
\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage{filecontents}
\begin{filecontents}{\jobname.bib}
@Book{test1,
author = {Goossens, Michel and Mittelbach, Frank
and Samarin, Alexander},
title = {The LaTeX Companion},
publisher = {Addison-Wesley},
location = {Reading, Mass.},
year = {1994},
}
@Book{test2,
author = {Mittelbach, Frank and Goossens, Michel
and Samarin, Alexander},
title = {The LaTeX Companion},
publisher = {Addison-Wesley},
location = {Reading, Mass.},
year = {1994},
}
@Book{test3,
author = {Mittelbach, Frank and Samarin, Alexander
and Goossens, Michel},
title = {The LaTeX Companion},
publisher = {Addison-Wesley},
location = {Reading, Mass.},
year = {1994},
}
\end{filecontents}
\usepackage[style=authoryear,minnames=8,maxnames=10]{biblatex}
\addbibresource{\jobname.bib}
\newcommand*{\mknamesignature}[5]{\def#1{#2|#3|#4|#5}}
\mknamesignature{\highlightname}{Goossens}{Michel}{}{}
\def\shortform{MG}
\makeatletter
\DeclareNameFormat{labelname}{%
\begingroup
\mknamesignature{\currentsignature}{#1}{#3}{#5}{#7}%
\ifdefequal{\highlightname}{\currentsignature}%
{\let\mkbibnamefirst=\@gobble%
\def\mkbibnamelast{\shortform\@gobble}%
\let\mkbibnameprefix=\@gobble%
\let\mkbibnameaffix=\@gobble}%
{}%
\ifnum\value{listcount}=1\relax
\usebibmacro{name:last-first}{#1}{#3}{#5}{#7}%
\ifblank{#3#5}
{}
{\usebibmacro{name:revsdelim}}%
\else
\usebibmacro{name:first-last}{#1}{#3}{#5}{#7}%
\fi
% Ende der Gruppe
\endgroup
\usebibmacro{name:andothers}}
\makeatother
\begin{document}
Test
\cite{test1}
\cite{test2}
\cite{test3}
\printbibliography
\end{document}
EDIT 1: Fixed spacing problem
Firstly create a dummy bibtex database having filename localbib.bib
\begin{filecontents}{localbib.bib}
@book{ mykey,
title = {The Title},
year = {2013},
author = {Doe, John},
address = {Antarctica}
}
\end{filecontents}
For the actual document, assuming `localbib.bib' as the database.
%Declare document class
\documentclass{article}
%Use Natbib and declare style options
\usepackage[numbers,square,sort&compress]{natbib}
%State database filename
\def\mybibtexdatabase{localbib} % <----- Change `localbib` here for your actual filename
%Import usebib package and declare the fields that can be used.
\usepackage{usebib}
\newbibfield{author}
\newbibfield{address}
\bibinput{\mybibtexdatabase}
%Now write the document
\begin{document}
%Example of usebibentry
Example of field citation is that %
\usebibentry{mykey}{author} is from \usebibentry{mykey}{address}, %
the publication was made in \usebibentry{mykey}{year}\citep{mykey}
%Existing methodology
\citeauthor{mykey} is the standard name citation.
%Bibliography
\bibliographystyle{apacite}
\bibliography{\mybibtexdatabase}
\end{document}
NOTE: In order to be able to use additional fields (ie for example doi, title, editor etc...) via the \usebibentry{KEY}{FIELD}
command, a \newbibfield{FIELD}
directive needs to be added to the preamble, just like it has been done ere for author and address.
Best Answer
Use the package option
longnamesfirst
to achieve that, i.e.,