I am using the \citep
command in my LaTeX document to cite references, and I expect it to format the references using "et al." when there are multiple authors, as shown in examples I've seen. However, when I compile my document, the full list of authors is displayed instead of the "et al." abbreviation for the 2nd but not the 1st example.
Moreover, I used the suggestion given in the Tex to its backwards: How to change citation call-outs from authoryear-style to numeric-style?
Here is the setup I’m using:
- I downloaded the
cas-model2-names.bst
file from this GitHub link. - My bibliography file is correctly referenced in the LaTeX document.
- I am using the
natbib
package for citations, and the document class is compatible with this bibliography style.
Here is a minimal example of my LaTeX code:
%\documentclass[a4paper,fleqn,longmktitle]{cas-sc}
\documentclass[a4paper,fleqn]{cas-sc}
% \usepackage[numbers]{natbib}
\usepackage[authoryear]{natbib}
\begin{document}
\section{Sample1}
\section{Sample2}
\section{Sample3}
\section{Bibliography styles}
This is a citation example 1: \citep{menezes2017towards} found that...
This is a citation example 2 \citep{menezes2017towards}] obtained a different result ...
%% Loading bibliography style file
\bibliographystyle{cas-model2-names}
% Loading bibliography database
\bibliography{cas-refs}
\end{document}
Expected Output:
This is a citation example 1: (Menezes et al. 2017) found that...
Actual Output:
This is a citation example 1: Menezes, Samara, Galway, Sant’Anna, Verikas, Alonso-Fernandez, Wang and Bond (2017) found that...
The example given in the Elsevier Template shows as: .
Whereas the other option \citet
gives a similar result.
Output:
cas-ref.bib
file
title={Lorem ipsum dolor sit amet, consectetur adipiscing elit. Praesent pellentesque ex id ligula efficitur},
author={Menezes, Maria Luiza Recena and Samara, Anas and Galway, Leo and Sant’Anna, Anita and Verikas, Antanas and Alonso-Fernandez, Fernando and Wang, Hui and Bond, Raymond},
journal={Lorem ipsum dolor},
volume={21},
pages={1003--1013},
year={2017},
publisher={Springer}
}
@article{luque2019impact,
title={Lorem ipsum dolor sit amet, consectetur adipiscing elit. Praesent pellentesque ex id ligula efficitur},
author={Luque, Amalia and Carrasco, Alejandro and Mart{\'\i}n, Alejandro and de Las Heras, Ana},
journal={Lorem ipsum},
volume={91},
pages={216--231},
year={2019},
publisher={Elsevier}
}
Update
For references cited a second time, the output is as expected. In the image below, Examples 1 and 3 are in an incorrect format, while Examples 2 and 4 are in the expected format.
\section{Bibliography styles}
This is a citation example 1: \citep{menezes2017towards} found that...
This is a citation example 2: \citep{menezes2017towards} obtained a different result ...
This is a citation example 3: \citep{luque2019impact} obtained a different result ...
This is a citation example 4: \citep{luque2019impact} obtained an expected result ...
Output:
cas-sc
document class loadnatbib
automatically? If so, with which options?natbib
package with the optionlongnamesfirst
. Get rid of this option if you want truncated citation call-outs right away.natbib
with the optionlongnamesfirst
) was resolved in a comment.