[Tex/LaTex] How to cite a reference on Beamer as (author, year)

beamerciting

How can I change the citation style to "( author , year )" on beamer? The code is for "author year"

\documentclass{beamer}
\usepackage[backend=bibtex,style=authoryear]{biblatex}
\addbibresource{ppgeq.bib}

\usetheme{Madrid}
\begin{document}
\section{}
\subsection{}
\begin{frame}{\secname}{\subsecname}
\cite{Wang2005}
\end{frame}
\end{document}

Best Answer

I would recommend using biber (the default) instead of bibtex as the back end for using biblatex. With the standard author-year style, there are two main citation commands:

  • \textcite{} produces Author yyyy
  • \parencite{} produces (Author yyyy)

To get the comma between the name and the year, you need:

  • \renewcommand*{\nameyeardelim}{\addcomma\addspace}

So here's a complete example of what you want:

\documentclass{beamer}
\begin{filecontents}{\jobname.bib}
@book{Saussure1995,
    Author = {Ferdinand de Saussure},
    Publisher = {Payot},
    Title = {Cours de Linguistique G{\'e}n{\'e}rale},
    Year = {1995}}
\end{filecontents}
\usetheme{Madrid}
\usepackage[style=authoryear]{biblatex}
\renewcommand*{\nameyeardelim}{\addcomma\addspace}

\addbibresource{\jobname.bib}
\begin{document}
\begin{frame}
\frametitle{A frame title}
\begin{itemize}
\item Langue et parole \parencite{Saussure1995}
\end{itemize}
\end{frame}

\end{document}

For printing the bibliography, you should typically use [allowframebreaks] on the frame that contains the \printbibliography command.

output of slide

Related Question