如何使用名称而不是数字在文中按时间顺序和参考书目中按作者字母顺序获取参考文献

如何使用名称而不是数字在文中按时间顺序和参考书目中按作者字母顺序获取参考文献

我是 LaTeX 新手。我即将完成我的论文,我需要文内引用以作者年份而不是数字表示。我对参考文献进行了排序,文内引用以作者年份为顺序排列,参考书目也以作者顺序排列。

在此处输入图片描述

在此处输入图片描述

现在有人告诉我,文内引用仍应为作者年份,但应按时间顺序排列。我使用了以下代码:

\documentclass[12pt,twoside]{book} %,PageStyleII,times,numbering,print,custombib
\usepackage{geometry}                       % See geometry.pdf to learn the layout options. There are lots.
\geometry{a4paper}                          % ... or a4paper or a5paper or ... 
\usepackage{floatrow}
\usepackage{setspace}
\usepackage{caption}
\usepackage{subcaption}
\usepackage{graphicx}
\usepackage{lscape}
%\usepackage{float}
\usepackage{booktabs}
\captionsetup[figure]{font={small}, skip=1pt, singlelinecheck=false}
\captionsetup[subfigure]{font={small}, skip=1pt, singlelinecheck=false}
\captionsetup{labelfont=bf}
\captionsetup[table]{font={small}, skip=1pt, singlelinecheck=false}
\raggedbottom
\usepackage{lineno}
\usepackage{mathtools}
\usepackage[all]{nowidow}

\usepackage{cite}
\usepackage{natbib}
\renewcommand\bibname{References}
\usepackage[nottoc]{tocbibind}

\begin{document}

\mainmatter
\Include(Intro)
    

% ********************************** Bibliography ******************************
\begin{spacing}{0.9}

%\addcontentsline{toc}{section}{References}
\bibliographystyle{apalike}%{agsm}apalike, chronological
\bibliography{references} % Path to your References.bib file

\cleardoublepage
\end{spacing}

\end{document}

当我更改为 \bibliographystyle{chronological} 时,它会根据我的需要将文内参考文献显示为作者年份但按时间顺序排列,但参考书目也是按时间顺序排列,而不是按作者的字母顺序排列。

在此处输入图片描述

在此处输入图片描述

有没有一种风格可以按时间顺序列出文内参考文献,按字母顺序列出参考书目?我见过很多使用 natbib 等看似非常复杂的解决方法,但我想知道是否有一种风格可以自动做到这一点?

我找到了这个biblatex - 按时间顺序引用,但参考书目列表必须按字母顺序排列但它对我不起作用。

已编辑:这是 Intro.tex 文件和 references.bib 文件的代码,用于测试(抱歉,不知道如何附加这些文件)。

简介:

\chapter{Introduction}

I would like there references in-text in the chapter to be in chronological order \citep{Carr1983, Brooker2018, Harrison2010, Dickson2023}, while they are alphabetical by author in the Bibliography.

参考文献.bib:

@article{Carr1983,
author = {Carr, Michael H.},
doi = {10.1016/0019-1035(83)90168-9},
file = {:Users/LA/Library/Application Support/Mendeley Desktop/Downloaded/Carr - 1983 - Stability of streams and lakes on Mars.pdf:pdf},
issn = {10902643},
journal = {Icarus},
number = {3},
pages = {476--495},
title = {{Stability of streams and lakes on Mars}},
volume = {56},
year = {1983}
}
@article{Brooker2018,
author = {Brooker, L. M. and Balme, M. R. and Conway, S. J. and Hagermann, A. and Barrett, A. M. and Collins, G. S. and Soare, R. J.},
doi = {10.1016/j.icarus.2017.11.022},
file = {:Users/LA/Library/Application Support/Mendeley Desktop/Downloaded/Brooker et al. - 2018 - Clastic polygonal networks around Lyot crater, Mars Possible formation mechanisms from morphometric analysis.pdf:pdf},
issn = {10902643},
journal = {Icarus},
keywords = {Geological processes,Mars,climate,surface},
pages = {386--406},
publisher = {Elsevier Inc.},
title = {{Clastic polygonal networks around Lyot crater, Mars: Possible formation mechanisms from morphometric analysis}},
url = {https://doi.org/10.1016/j.icarus.2017.11.022},
volume = {302},
year = {2018}
}
@article{Harrison2010,
author = {Harrison, Tanya N. and Malin, Michael C. and Edgett, Kenneth S. and Shean, David E. and Kennedy, Megan R. and Lipkaman, Leslie J. and Cantor, Bruce A. and Posiolova, Liliya V.},
doi = {10.1029/2010GL045074},
file = {:Users/LA/Library/Application Support/Mendeley Desktop/Downloaded/Harrison et al. - 2010 - Impact-induced overland fluid flow and channelized erosion at Lyot Crater, Mars.pdf:pdf},
issn = {00948276},
journal = {Geophysical Research Letters},
keywords = {http://dx.doi.org/10.1029/2010GL045074, doi:10.102},
number = {21},
pages = {1--6},
title = {{Impact-induced overland fluid flow and channelized erosion at Lyot Crater, Mars}},
volume = {37},
year = {2010}
}
@article{Dickson2023,
author = {Dickson, J L and Palumbo, A M and Head, J W and Kerber, L and Fassett, C I and Kreslavsky, M A},
doi = {10.1126/science.abk2464},
file = {:Users/LA/Library/Application Support/Mendeley Desktop/Downloaded/Dickson et al. - 2023 - Gullies on Mars could have formed by melting of water ice during periods of high obliquity.pdf:pdf},
issn = {0036-8075},
journal = {Science},
month = {jun},
number = {6652},
pages = {1363--1367},
title = {{Gullies on Mars could have formed by melting of water ice during periods of high obliquity}},
url = {https://www.science.org/doi/10.1126/science.abk2464},
volume = {380},
year = {2023}
}

答案1

使用 biblatex+ biber 会相当简单,正如您链接的问题中的答案所示。使用 natbib 会更困难一些,但您可以尝试以下操作。不要使用cite带有 的包natbibnatbib它有自己的代码。我添加了Dickson2023-b带有额外年份后缀的测试条目。

\documentclass{article}
\begin{filecontents}[overwrite]{test-order.bib}
@article{Carr1983,
author = {Carr, Michael H.},
doi = {10.1016/0019-1035(83)90168-9},
file = {:Users/LA/Library/Application Support/Mendeley Desktop/Downloaded/Carr - 1983 - Stability of streams and lakes on Mars.pdf:pdf},
issn = {10902643},
journal = {Icarus},
number = {3},
pages = {476--495},
title = {{Stability of streams and lakes on Mars}},
volume = {56},
year = {1983}
}
@article{Brooker2018,
author = {Brooker, L. M. and Balme, M. R. and Conway, S. J. and Hagermann, A. and Barrett, A. M. and Collins, G. S. and Soare, R. J.},
doi = {10.1016/j.icarus.2017.11.022},
file = {:Users/LA/Library/Application Support/Mendeley Desktop/Downloaded/Brooker et al. - 2018 - Clastic polygonal networks around Lyot crater, Mars Possible formation mechanisms from morphometric analysis.pdf:pdf},
issn = {10902643},
journal = {Icarus},
keywords = {Geological processes,Mars,climate,surface},
pages = {386--406},
publisher = {Elsevier Inc.},
title = {{Clastic polygonal networks around Lyot crater, Mars: Possible formation mechanisms from morphometric analysis}},
url = {https://doi.org/10.1016/j.icarus.2017.11.022},
volume = {302},
year = {2018}
}
@article{Harrison2010,
author = {Harrison, Tanya N. and Malin, Michael C. and Edgett, Kenneth S. and Shean, David E. and Kennedy, Megan R. and Lipkaman, Leslie J. and Cantor, Bruce A. and Posiolova, Liliya V.},
doi = {10.1029/2010GL045074},
file = {:Users/LA/Library/Application Support/Mendeley Desktop/Downloaded/Harrison et al. - 2010 - Impact-induced overland fluid flow and channelized erosion at Lyot Crater, Mars.pdf:pdf},
issn = {00948276},
journal = {Geophysical Research Letters},
keywords = {http://dx.doi.org/10.1029/2010GL045074, doi:10.102},
number = {21},
pages = {1--6},
title = {{Impact-induced overland fluid flow and channelized erosion at Lyot Crater, Mars}},
volume = {37},
year = {2010}
}
@article{Dickson2023,
author = {Dickson, J L and Palumbo, A M and Head, J W and Kerber, L and Fassett, C I and Kreslavsky, M A},
doi = {10.1126/science.abk2464},
file = {:Users/LA/Library/Application Support/Mendeley Desktop/Downloaded/Dickson et al. - 2023 - Gullies on Mars could have formed by melting of water ice during periods of high obliquity.pdf:pdf},
issn = {0036-8075},
journal = {Science},
month = {jun},
number = {6652},
pages = {1363--1367},
title = {{Gullies on Mars could have formed by melting of water ice during periods of high obliquity}},
url = {https://www.science.org/doi/10.1126/science.abk2464},
volume = {380},
year = {2023}
}

@article{Dickson2023-b,
author = {Dickson, J L and Palumbo, A M and Head, J W and Kerber, L and Fassett, C I and Kreslavsky, M A},
doi = {10.1126/science.abk2464},
file = {:Users/LA/Library/Application Support/Mendeley Desktop/Downloaded/Dickson et al. - 2023 - Gullies on Mars could have formed by melting of water ice during periods of high obliquity.pdf:pdf},
issn = {0036-8075},
journal = {Science},
month = {jun},
number = {6652},
pages = {1363--1367},
title = {{Gullies on Mars could have formed by melting of water ice during periods of high obliquity}},
url = {https://www.science.org/doi/10.1126/science.abk2464},
volume = {380},
year = {2023}
}
\end{filecontents}
\usepackage[sort]{natbib}
\makeatletter
\ExplSyntaxOn

\AddToHook{cmd/NAT@sort@cites/after}{\mart_sort_cites:N\NAT@cite@list}% 
 
\cs_new_protected:Npn \mart_sort_cites:N #1
  { 
    \clist_sort:Nn #1
     {
       \NAT@parse {##1}       
       \regex_extract_once:nVNF {\d+}\NAT@date \l_tmpa_seq
         {\seq_put_right:Nn\l_tmpa_seq{9999}}       
       \NAT@parse {##2}       
       \regex_extract_once:nVNF {\d+}\NAT@date \l_tmpb_seq
         {\seq_put_right:Nn\l_tmpb_seq{9999}}       
       \int_compare:nNnTF 
         { \seq_item:Nn \l_tmpa_seq {1} }> {\seq_item:Nn \l_tmpb_seq {1}}
         {\sort_return_swapped:}
         {\sort_return_same:}        
     }
  }
  
\ExplSyntaxOff 
\makeatother

\begin{document}
\citep{Dickson2023-b,Carr1983, Brooker2018, Harrison2010, Dickson2023}
\bibliographystyle{apalike}%{agsm}apalike, chronological
\bibliography{test-order} % Path to your References.bib file

\end{document}

在此处输入图片描述

相关内容