【发布时间】:2021-12-28 06:39:00
【问题描述】:
我目前正在尝试在使用 csl 文件时将我的书目正确格式化为 Rmarkdown 文件。
当使用 natbib 时,ref-items 之间的间距可以正常工作,但是使用 csl 文件时,它不会产生正确的间距。
出于其他几个原因,我不想使用 natbib 但 csl
因为 \setlength\bibitemsep 或类似的东西不适用于 csl。
YAML
font-family: Arial
mainfont: Arial
header-includes:
- \pagenumbering{gobble}
- \usepackage{caption}
- \usepackage{float}
- \captionsetup[figure]{font=footnotesize,format=hang,labelfont=bf,textfont=it,width=.95\textwidth}
output:
bookdown::pdf_document2:
includes:
text-align: justify
latex_engine: "xelatex"
number_sections: yes
fig_caption: yes
toc: false
geometry: "left=3cm,right=3cm,top=2.5cm,bottom=2.5cm"
fontsize: 12pt
bibliography: Microt.bib
csl: the-journal-of-cell-biology.csl
linestretch: 1.5
link-citations: yes
editor_options:
markdown:
wrap: sentence
然后在rmd的末尾:
\```{=tex}
\newpage
\pagenumbering{gobble}
\```
# Literature {.unnumbered}
\singlespacing
使用 csl 的空间很小
使用 natbib 空格很好
citation_package: natbib 在 YAML 中
但条目太冗长
不学习Latex几个星期和tlmgr等战斗有什么好的解决方案吗?
【问题讨论】:
-
你能在一个文件中创建一个minimal reproducible example,其中实际上有引用来生成参考书目吗?
标签: r r-markdown bibtex xelatex csl