1

I want to change the style of the short names for the citations in the text. The implementation of biblatex I am using is as follows:

\usepackge[
style=alphabetic,
isbn=false,
doi=false,
url=false,
firstinits=true, 
pagetracker=true,
maxbibnames=50,
maxcitenames=1, 
minalphanames=1,
autocite=inline,
block=space,
backref=true,
backrefstyle=three+,
date=short,
backend=bibtex,
bibencoding=UTF8
]{biblatex}

This works fine so far. It produces a bibliography that looks like this:

I want to change the citations in brackets on the left. Currently they take the first three letters for one author, for more authors it just takes the first letter for each the authors and for mor than 3 authors it takes the first 3 letters of the first author and adds a plus. After that they get two numbers for the year.

Now I want that all papers just get the first three letters of the first authors last name (and the two numbers for the year). In my citavi .bib file it is set that way but I don't know how to change this in latex.

EDIT: Ok good news, it did work and the bibliography looks just the way I wanted, thanks a lot!

enter image description here

But now there have appeared some error masseges at the print bibliography:

enter image description here

And the errors say:

enter image description here

I appreciate the help, thanks. Daniel

7
  • Check your .bib entry for " characters and please post a complete example document including relevant .bib entries that reproduces the error. Make the example as small as possible while still reproducing the problem.
    – moewe
    Commented Apr 13, 2020 at 12:00
  • I've created a small example in which I used my .bib file. I cited every paper in the .bib file and it worked fine, no warnings or problems. The problem only occurs in my full Latex project.
    – Daniel
    Commented Apr 13, 2020 at 13:40
  • Then add try to find the problematic code from your document by adding it in and removing it if it does not cause the error. This may take some time, but it's the only way to isolate the error. If you use the "binary search method" (start from a copy of your original document, delete half of the code, see if the problem persists, if yes, continue, if not, add the old code back in and delete the other half, repeat.)
    – moewe
    Commented Apr 13, 2020 at 13:44
  • Thanks, that sound tedious but I guess I don't have another choice. I will try that later when I get the time. But thanks a lot for the effort.
    – Daniel
    Commented Apr 13, 2020 at 17:28
  • It's not that bad. If you follow the binary search method you can reduce a document with $n$ lines in $\log_2(n)$ steps: 1000 lines are analysed in about 10 steps. Plus there are certain things you can focus on quite quickly. You can probably remove almost all text from your document right away, this problem appears to be related to the bibliography (certain bibliography entries) and the preamble. Find out which packages cause this. Find out which .bib entries cause this. (Remember to delete the .aux, .bbl and .bcf files between compilations to avoid corrupted temporary files.)
    – moewe
    Commented Apr 13, 2020 at 17:31

1 Answer 1

1

With BibTeX as backend (backend=bibtex,) there is no official biblatex interface to modify the alphabetic label in the way you want. You need to use Biber. Switching to Biber should be as easy as changing backend=bibtex, to backend=biber, and running Biber instead of BibTeX in the compilation cycle (if you are using an editor to help you compile your documents, see Biblatex with Biber: Configuring my editor to avoid undefined citations for help with setting it up to run Biber for you). (The keys generated by Citavi or other software has no bearing on the alphabetic label produced by biblatex.)

With Biber the alphabetic label can be easily customised with \DeclareLabelalphaTemplate. You'll also want to set maxalphanames=1, to make sure the label is only drawn from the first author. If you don't want to see the "+" for "et al." you can remove it with \renewcommand*{\labelalphaothers}{}.

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

\usepackage[style=alphabetic, maxalphanames=1, backend=biber]{biblatex}

\DeclareLabelalphaTemplate{
  \labelelement{
    \field[final]{shorthand}
    \field{label}
    \field[strwidth=3,strside=left]{labelname}
  }
  \labelelement{
    \field[strwidth=2,strside=right]{year}
  }
}

% if you want to suppress the "+" for "et al."
%\renewcommand*{\labelalphaothers}{}


\addbibresource{biblatex-examples.bib}

\begin{document}
\cite{sigfridsson,nussbaum,worman,geer,aksin,companion,herrmann}
\printbibliography
\end{document}

[Sig+98; Nus78; Wor02; Gee85; Aks+06; Goo+94; Her+06]

2
  • Very nice, but it doesn't seem to work for me right now. I've posted what I did in an answer above.
    – Daniel
    Commented Apr 12, 2020 at 20:37
  • @Daniel A screenshot of the code you used doesn't help with diagnosing the problem. Run the exact code I posted without any modifications. Do you get the output I show in my post? If not, are there errors or warnings in the .log file? Are the errors or warnings in the .blg file?
    – moewe
    Commented Apr 13, 2020 at 5:02

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .