1

I would like to add a citation in a legend entry in combination with using tikzexternalize. It seems like tikzexternalize is causing some errors here. The \cite{} command is not properly converting the bibitem to the desired citation.

Here is a MWE

\documentclass{article}
\usepackage{pgfplots}
\pgfplotsset{compat=newest}

\usepgfplotslibrary{external}
\tikzexternalize[prefix=tikz/]

\usepackage[backend=biber]{biblatex}
\begin{filecontents}[overwrite]{refs.bib}
@Book{test, title = "Title"}
\end{filecontents}
\addbibresource{refs.bib}

\begin{document}
\begin{tikzpicture}
\begin{axis}
\addplot {x^2};
\addlegendentry{Differentiator from {\cite{test}}}
\end{axis}
\end{tikzpicture}

\printbibliography
\end{document}

Removing the two lines

\usepgfplotslibrary{external}
\tikzexternalize[prefix=tikz/]

yields the desired output. Is there a workaround to use the \cite{} command in combination with tikzexternalize?

1

0

You must log in to answer this question.

Browse other questions tagged .