0

I'm trying to edit the bibliography style of the biblatex style apa. With the help of Google, I'm almost done, but there are some few adjustments that have to be done. My style looks like that:

Arlot, S./Celisse, A. (2010): A survey of cross-validation procedures for model selection, in: Statistics Surveys, 4(1), 40-79.

But has to look like:

Arlot, S./Celisse, A. (2010): A survey of cross-validation procedures for model selection, in: Statistics Surveys, 4(1), 40-79.

  1. Authors have to be bold
  2. I need the volume number not in italic
  3. If possible an "in" between title and journal would be nice.

This is my code:

\usepackage[backend=biber,style=apa, maxcitenames=4,natbib=true,doi=false]{biblatex}
\usepackage{letltxmacro}
\usepackage{csquotes}
\usepackage{xpatch}
\LetLtxMacro{\cite}{\citet}                     %Year in brackets
\renewcommand{\labelnamepunct}{\addcolon\space} %Colon after year
% Slash instead of comma (und &)
\DeclareDelimFormat*{multinamedelim}{\,/\,} 
\DeclareDelimFormat*{finalnamedelim}{} 
\DeclareDelimAlias{finalnamedelim}{multinamedelim} 
\DeclareDelimFormat*{finalnamedelim:apa:family-given}{}
\DeclareDelimAlias{finalnamedelim:apa:family-given}{multinamedelim} 

The .bib file contains:

@article{Arlot.2010,
 author = {Arlot, Sylvain and Celisse, Alain},
 year = {2010},
 title = {A survey of cross-validation procedures for model selection},
 pages = {40--79},
 volume = {4},
 issn = {1935-7516},
 journal = {Statistics Surveys},
 doi = {10.1214/09-SS054}}
1

From the output you currently get I'm inferring that you are using an older version of biblatex-apa that produces citations and bibliography entries according to 6th ed. APA style. Currently, biblatex-apa produces 7th-ed. APA style and 6th-ed. APA style can be obtained from biblatex-apa6's style=apa6. That's why the MWE uses style=apa6.

\documentclass[british]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{babel}
\usepackage{csquotes}

\usepackage[backend=biber, style=apa6, maxcitenames=4,natbib=true, doi=false]{biblatex}

\DeclareDelimFormat[bib]{nametitledelim}{\addcolon\space}

\DeclareDelimFormat*{multinamedelim}{/} 
\DeclareDelimFormat*{finalnamedelim}{} 
\DeclareDelimAlias{finalnamedelim}{multinamedelim} 
\DeclareDelimFormat*{finalnamedelim:apa:family-given}{}
\DeclareDelimAlias{finalnamedelim:apa:family-given}{multinamedelim}

% 1: Bold names
\renewbibmacro*{author}{%
  \printtext[bold]{%
  \ifnameundef{author}
    {\usebibmacro{labeltitle}}
    {\printnames[apaauthor][-\value{listtotal}]{author}%
     \setunit*{\addspace}%
     \printfield{nameaddon}%
     \ifnameundef{with}
       {}
       {\setunit{}\addspace\mkbibparens{\printtext{\bibstring{with}\addspace}%
        \printnames[apaauthor][-\value{listtotal}]{with}}
        \setunit*{\addspace}}}%
  \newunit\newblock%
  \usebibmacro{labelyear+extradate}}}

\renewbibmacro*{editorinauthpos}{%
  \printtext[bold]{%
    \global\booltrue{bbx:editorinauthpos}%
    \printnames[apaauthor][-\value{listtotal}]{editor}%
    \setunit{\addspace}%
    \ifnameundef{editor}
      {}
      {\printtext[parens]{\usebibmacro{apaeditorstrg}{editor}}%
       % need to clear editor so we don't get an "In" clause later
       % But we also need to set a flag to say we did this so we
       % don't lose sight of the fact we once had an editor for
       % various year placement tests
       \clearname{editor}%
       \setunit{\adddot\addspace}%
       \usebibmacro{labelyear+extradate}%
       \setunit{\adddot\addspace}}}}

% 2: plain volume numbers
\DeclareFieldFormat[article,periodical]{volume}{\apanum{#1}}

% 3: in for @articles
\usepackage{xpatch}

\xpatchbibdriver{article}
  {\usebibmacro{journal+issuetitle}}
  {\usebibmacro{in}%
   \usebibmacro{journal+issuetitle}}
  {}{}

\renewbibmacro*{in}{%
  \ifbool{bbx:in}%
    {}%
    {\global\booltrue{bbx:in}%
     \setunit{\addcomma\space}%
     \bibstring{in}%
     \printunit{\intitlepunct}}}

\begin{filecontents}{\jobname.bib}
@article{Arlot.2010,
  author  = {Arlot, Sylvain and Celisse, Alain},
  year    = {2010},
  title   = {A survey of cross-validation procedures for model selection},
  pages   = {40--79},
  volume  = {4},
  issn    = {1935-7516},
  journal = {Statistics Surveys},
  doi     = {10.1214/09-SS054},
}
\end{filecontents}
\addbibresource{\jobname.bib}


\begin{document}
\cite{Arlot.2010}
\printbibliography
\end{document}

**Arlot, S./Celisse, A. (2010):** A survey of cross-validation procedures for model selection, in: *Statistics Surveys*, 4, 40–79.


It should be noted that it can be quite tricky to modify biblatex-apa or biblatex-apa6 since the styles were specifically written to comply to the at times complex APA guidelines and are in general not intended to be customised beyond APA requirements.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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