[Tex/LaTex] How to differentiate between translated and reprinted work with APA style

apa-stylebiblatexbibliographiesbibtexciting

This question is an upgrade to this (already answered) question.

I am using biblatex-apa with biber as backend.

According to the APA style a "translated" work should be treated differently from a "reprinted" work. A "translated" work will simply indicate the translator and at the end the original date of publication (...Somepress. (Original work published 1923)), without indicating any other additional information about the source work on which the translation is based. Similarly to a "republished" or "reprinted book". On the contrary a "reprinted chapter" will need to indicate the original title of the book, pages the chapter/article was originally published at, author/editor of the original book, year of original publication, city and publisher.

I have then added two fields to my bibliography to store information on reference to original work reprintedfrom (in case the chapter/article was already printed) and original publication pages origpages.

I am then looking for a macro that will tell the difference between a translated, republished or reprinted book and a republished chapter/article.

In the first case should print

Buber, M. (1937). I and thou (R. G. Smith, Trans.). Edinburgh: T. & T.
Clark. (Original work published 1923)

with in-text parenthetical citations: (Buber, 1923/1937);

while in the second

Cohen, J. (1997). Deliberation and democratic legitimacy. In J. Bohman
& W. Rehg (Eds.), Deliberative democracy: Essays on reason and
politics
(pp. 67–91). Cambridge, MA: MIT Press. (Reprinted from The
Good polity: Normative analysis of the state
, pp. 17-34, by A. P.
Hamlin & P. Pettit, Eds., 1989, Oxford: Blackwell)

with in-text parenthetical citations: (Cohen, 1989/1997).

This answer offers a macro to add fields to the bibliography for specific bib items and add them at the end of reference:

Cohen, J. (1997). Deliberation and democratic legitimacy. In J. Bohman
& W. Rehg (Eds.), Deliberative democracy: Essays on reason and
politics
(pp. 67–91). Cambridge, MA: MIT Press. (Reprinted from The
Good polity: Normative analysis of the state
, by A. P.
Hamlin & P. Pettit, Eds., 1989, Oxford: Blackwell) (Original work published 1989)

Problem is it won't add the number of pages for the original work and won't remove (Original work published 1989) that now is redundant in the complete citation.

I am interested to know if it is possible to tweak these macros to obtain the different citation styles as described above.

Please consider the following

\RequirePackage{filecontents}

\begin{filecontents*}{mybib.bib}
@book{test1,
    address = {Edinburgh},
    title = {I and thou},
    publisher = {T. \& {T}. {Clark}},
    author = {Buber, Martin},
    translator = {Smith, Ronald Gregor},
    year = {1937},
    origdate = {1923}
}
@incollection{test2,
    address = {Cambridge, {MA}},
    title = {Deliberation and democratic legitimacy},
    booktitle = {Deliberative democracy: {Essays} on reason and politics},
    publisher = {MIT {Press}},
    author = {Cohen, Joshua},
    editor = {Bohman, James and Rehg, William},
    year = {1997},
    origdate = {1989},
    reprintedfrom = {test3},
    origpages = {17--34},
    pages = {67--91}
}
@book{test3,
    address = {Oxford},
    title = {The {Good} polity: {Normative} analysis of the state},
    shorttitle = {The {Good} polity},
    publisher = {Blackwell},
    editor = {Hamlin, Alan P. and Pettit, Philip},
    year = {1989}
}
}
\end{filecontents*}

\documentclass[a4paper]{article}


% Set the values for the bibliography
\usepackage[
    style=apa,
    backend=biber,
    isbn=false,
    url=false,
    doi=false,
    eprint=false,
    hyperref=true,
    backref=false,
    firstinits=false,
]{biblatex}

% Recommended by biblatex
\usepackage[utf8]{inputenc}
\usepackage{csquotes}
\usepackage{xpatch}

% Set language
\usepackage[british]{babel}
\DeclareLanguageMapping{british}{british-apa}

\addbibresource{mybib.bib}

\begin{document}

\cite{test1} 

\cite{test2}

\printbibliography
\end{document}

This is the output

enter image description here

while I am trying to get

enter image description here

Best Answer

You might want to try this slightly modified mapping command

\DeclareSourcemap{
  \maps[datatype=bibtex]{
    \map{
      \step[fieldsource=reprintedfrom, fieldtarget=related, final]
      \step[fieldset=relatedtype, fieldvalue={reprintfrom}]
    }
  }
}

It will turn the non-standard reprintedfrom={something} into related={something} and relatedtype={reprintfrom}.

\RequirePackage{filecontents}
\begin{filecontents*}{\jobname.bib}
@book{test1,
    address = {Edinburgh},
    title = {I and thou},
    publisher = {T. \& {T}. {Clark}},
    author = {Buber, Martin},
    translator = {Smith, Ronald Gregor},
    year = {1937},
    origdate = {1923}
}
@incollection{test2,
    address = {Cambridge, {MA}},
    title = {Deliberation and democratic legitimacy},
    booktitle = {Deliberative democracy: {Essays} on reason and politics},
    publisher = {MIT {Press}},
    author = {Cohen, Joshua},
    editor = {Bohman, James and Rehg, William},
    year = {1997},
    origdate = {1989},
    reprintedfrom = {test3},
    pages = {67--91},
}
@book{test3,
    address = {Oxford},
    title = {The {Good} polity: {Normative} analysis of the state},
    shorttitle = {The {Good} polity},
    publisher = {Blackwell},
    editor = {Hamlin, Alan P. and Pettit, Philip},
    year = {1989},
    pages = {17--34},% that's better than origpages in test2
}
}
\end{filecontents*}

\documentclass[a4paper]{article}


% Set the values for the bibliography
\usepackage[
    style=apa,
    backend=biber,
    isbn=false,
    url=false,
    doi=false,
    eprint=false,
    hyperref=true,
    backref=false,
    firstinits=false,
]{biblatex}

% Recommended by biblatex
\usepackage[utf8]{inputenc}
\usepackage{csquotes}
\usepackage{xpatch}

% Set language
\usepackage[british]{babel}
\DeclareLanguageMapping{british}{british-apa}

\addbibresource{\jobname.bib}

\renewbibmacro*{related:reprintfrom}[1]{%
  \entrydata*{#1}{%
    \printtext{\mkbibemph{\printfield[apacase]{title}}}%
    \setunit{\bibpagespunct}%
    \printfield{pages}%
    \setunit{\addcomma\addspace}%
    \bibstring{byauthor}\addspace
    \printnames[apanames][-\value{listtotal}]{editor}%
    \ifnameundef{editor}
      {}
      {\addcomma\addspace
       \usebibmacro{apaeditorstrg}{editor}}
    \printnames[apanames][-\value{listtotal}]{author}%
    \setunit{\addcomma\addspace}%
    \usebibmacro{date}%
    \setunit{\addcomma\addspace}%
    \usebibmacro{location+publisher}%
    \newunit\newblock
    \usebibmacro{related}}}


\DefineBibliographyStrings{british}{
  reprintfrom = {Reprinted from}
}

\DeclareSourcemap{
  \maps[datatype=bibtex]{
    \map{
      \step[fieldsource=reprintedfrom, fieldtarget=related, final]
      \step[fieldset=relatedtype, fieldvalue={reprintfrom}]
    }
  }
}

\renewbibmacro*{origyear}{%
  \ifboolexpr{not test {\iffieldundef{labelyear}} and not test {\iffieldsequal{labelyear}{origyear}} and not test {\iffieldequalstr{relatedtype}{reprintfrom}}}
    {\printfield{origyear}}
    {}}

\begin{document}
  \cite{test1}
  \cite{test2}

  \printbibliography
\end{document}

A problem though is origpages; the best solution is to add the contents of origpages as pages to the related entry as done above.


But if you cannot, for the life of you, live with changing your bibsource, this redefinition of related:reprintfrom might be for you.

\DeclareFieldFormat{origpages}{\mkpageprefix[bookpagination]{#1}}

\renewbibmacro*{related:reprintfrom}[1]{%
  \entrydata*{#1}{%
    \printtext{\mkbibemph{\printfield[apacase]{title}}}}%
  \setunit{\bibpagespunct}%
  \printfield{origpages}%
  \entrydata*{#1}{%
    \setunit{\addcomma\addspace}%
    \bibstring{byauthor}\addspace
    \printnames[apanames][-\value{listtotal}]{editor}%
    \ifnameundef{editor}
      {}
      {\addcomma\addspace
       \usebibmacro{apaeditorstrg}{editor}}
    \printnames[apanames][-\value{listtotal}]{author}%
    \setunit{\addcomma\addspace}%
    \usebibmacro{date}%
    \setunit{\addcomma\addspace}%
    \usebibmacro{location+publisher}%
    \newunit\newblock
    \usebibmacro{related}}}

You will have to tell biblatex/Biber to recognise origpages though. This can be done via

\begin{filecontents*}{biblatex-dm.cfg}
\DeclareDatamodelFields[type=field,datatype=range]{origpages}
\DeclareDatamodelEntryfields{origpages}
\end{filecontents*}

Another MWE

\RequirePackage{filecontents}
\begin{filecontents*}{biblatex-dm.cfg}
\DeclareDatamodelFields[type=field,datatype=range]{origpages}
\DeclareDatamodelEntryfields{origpages}
\end{filecontents*}

\begin{filecontents*}{\jobname.bib}
@book{test1,
    address = {Edinburgh},
    title = {I and thou},
    publisher = {T. \& {T}. {Clark}},
    author = {Buber, Martin},
    translator = {Smith, Ronald Gregor},
    year = {1937},
    origdate = {1923}
}
@incollection{test2,
    address = {Cambridge, {MA}},
    title = {Deliberation and democratic legitimacy},
    booktitle = {Deliberative democracy: {Essays} on reason and politics},
    publisher = {MIT {Press}},
    author = {Cohen, Joshua},
    editor = {Bohman, James and Rehg, William},
    year = {1997},
    origdate = {1989},
    reprintedfrom = {test3},
    %related = {test3},
    %relatedtype={reprintfrom},
    origpages = {17--34},
    pages = {67--91}
}
@book{test3,
    address = {Oxford},
    title = {The {Good} polity: {Normative} analysis of the state},
    shorttitle = {The {Good} polity},
    publisher = {Blackwell},
    editor = {Hamlin, Alan P. and Pettit, Philip},
    year = {1989}
}
}
\end{filecontents*}

\documentclass[a4paper]{article}


% Set the values for the bibliography
\usepackage[
    style=apa,
    backend=biber,
    isbn=false,
    url=false,
    doi=false,
    eprint=false,
    hyperref=true,
    backref=false,
    firstinits=false,
]{biblatex}

% Recommended by biblatex
\usepackage[utf8]{inputenc}
\usepackage{csquotes}
\usepackage{xpatch}

% Set language
\usepackage[british]{babel}
\DeclareLanguageMapping{british}{british-apa}

\addbibresource{\jobname.bib}

\DeclareFieldFormat{origpages}{\mkpageprefix[bookpagination]{#1}}

\renewbibmacro*{related:reprintfrom}[1]{%
  \entrydata*{#1}{%
    \printtext{\mkbibemph{\printfield[apacase]{title}}}}%
    \setunit{\bibpagespunct}%
    \printfield{origpages}%
  \entrydata*{#1}{%
    \setunit{\addcomma\addspace}%
    \bibstring{byauthor}\addspace
    \printnames[apanames][-\value{listtotal}]{editor}%
    \ifnameundef{editor}
      {}
      {\addcomma\addspace
       \usebibmacro{apaeditorstrg}{editor}}
    \printnames[apanames][-\value{listtotal}]{author}%
    \setunit{\addcomma\addspace}%
    \usebibmacro{date}%
    \setunit{\addcomma\addspace}%
    \usebibmacro{location+publisher}%
    \newunit\newblock
    \usebibmacro{related}}}


\DefineBibliographyStrings{british}{
  reprintfrom = {Reprinted from}
}

\DeclareSourcemap{
  \maps[datatype=bibtex]{
    \map{
      \step[fieldsource=reprintedfrom, fieldtarget=related, final]
      \step[fieldset=relatedtype, fieldvalue={reprintfrom}]
    }
  }
}

\renewbibmacro*{origyear}{%
  \ifboolexpr{not test {\iffieldundef{labelyear}} and not test {\iffieldsequal{labelyear}{origyear}} and not test {\iffieldequalstr{relatedtype}{reprintfrom}}}
    {\printfield{origyear}}
    {}}

\begin{document}
  \cite{test1} 
  \cite{test2}

  \printbibliography
\end{document}

To get rid of the origyear information at the end of a reprint, we modify the macro to include a test for reprinted entries (it checks if relatedtype is set to reprintfrom; the mapping takes care of that); the information is skipped if it is a reprint.

\renewbibmacro*{origyear}{%
  \ifboolexpr{not test {\iffieldundef{labelyear}} and not test {\iffieldsequal{labelyear}{origyear}} and not test {\iffieldequalstr{relatedtype}{reprintfrom}}}
    {\printfield{origyear}}
    {}}

Both MWEs yield

enter image description here