标签: csl

pandoc-citeproc如何排序引用?

我有一个pandoc风格的Markdown文本,我在同一个地方引用同一作者的两篇论文:

Lorem ipsum [@Author2000;@Author2001] dolor sit amet.
Run Code Online (Sandbox Code Playgroud)

这被渲染为

Lorem ipsum(作者2001,2000)dolor sit amet.

为什么这些引文按照这种方式排序,与我的文本中的顺序相矛盾,与作者年排序相矛盾,并且与它们在引用列表中出现的顺序相矛盾?我怎么能改变这个?是否可以关闭任何类型的排序并保持我指定引用的顺序?

更多信息:文本通过pandoc将选项--filter pandoc-citeproc --csl=elsevier-harvard.csl转换为latex,然后使用xelatex进行处理.csl文件可以从Zotero下载.Pandoc是v1.13.2,pandoc-citeproc是v0.6.

markdown pandoc csl

7
推荐指数
1
解决办法
953
查看次数

添加参考文献标题的链接

我正在使用 rmarkdown (pandoc) 创建一个文档,其中在.bib文件中包含一些参考书目。我想要做的是将链接添加到参考文献的标题,以便每个参考文献都链接到表单的页面http://sample.com/citation-key.html,如下所示:

\n\n
\n

作者。(2017)。示例标题。日记,1(1),1\xe2\x80\x932。

\n
\n\n

我尝试.csl通过向标题添加前缀和后缀来修改文件,但无论我使用 markdown 还是 HTML 语法,我放入其中的所有内容都会被转义。不幸的是,我无法更改该.bib文件。该文件的相关部分.csl是这样的:

\n\n
<text variable="title"/>\n
Run Code Online (Sandbox Code Playgroud)\n\n

示例文件是:

\n\n\n

bibliography pandoc r-markdown csl

6
推荐指数
1
解决办法
885
查看次数

如何在 Markdown 文件中的标点符号内移动上标引用编号?

我正在使用 Rmarkdown 写一篇带有引文的论文。当我使用 Nature 的 CSL(或任何上标数字样式)并使用 Pandoc 和 pandoc-citeproc 进行渲染时,行内引用位于标点符号之外。如何将它们移动到标点符号内?谢谢!

这是一个 Rmd 文件示例:

---
title: "Test"
author: "Daijiang Li"
date: '`r format(Sys.time(), "%d %B, %Y")`'
output:
  bookdown::pdf_document2:
    keep_tex: yes
    latex_engine: xelatex
    number_sections: no
    toc: no
fontsize: 12pt
linestretch: 1.5
link-citations: yes
csl: https://raw.githubusercontent.com/citation-style-language/styles/master/nature.csl
bibliography: ref.bib
references:
- id: fenner2012a
  title: One-click science marketing
  author:
  - family: Fenner
    given: Martin
  container-title: Nature Materials
  volume: 11
  URL: 'http://dx.doi.org/10.1038/nmat3283'
  DOI: 10.1038/nmat3283
  issue: 4
  publisher: Nature Publishing Group
  page: 261-263
  type: article-journal
  issued:
    year: …
Run Code Online (Sandbox Code Playgroud)

pandoc knitr r-markdown csl pandoc-citeproc

6
推荐指数
1
解决办法
1174
查看次数

在RMarkdown上指定CSL样式

我正在尝试在我的RMarkdown文档上指定CSL样式,如下所示

---
documentclass: article
fontsize: 12pt
linkcolor: blue
output: pdf_document
bibliography: bibliography.bib
csl: biomed-central.csl
---
Run Code Online (Sandbox Code Playgroud)

但这给我一个错误

pandoc-citeproc.exe: biomed-central.csl: openBinaryFile: does not exist (No such file or directory)
pandoc.exe: Error running filter pandoc-citeproc
Error: pandoc document conversion failed with error 83
Run Code Online (Sandbox Code Playgroud)

Windows 7 64 bitR Version 3.1.2RStudio 0.98.1091 如何我可以指定一个CSL样式。

r pandoc rstudio r-markdown csl

5
推荐指数
1
解决办法
2594
查看次数

Rmarkdown 中的引用:使用 .bib 文件中的标题大写

我正在使用 Rmarkdown 与 RStudio 和knitr. 为了格式化参考文献,我使用了Global Ecology and Biogeography.csl杂志的文件,该文件是我从https://www.zotero.org/styles获得的。

\n\n

我的问题是标题会自动转换为句子大小写。这对于小写的物种名称来说尤其成问题。

\n\n

例如,

\n\n
Two types of morphophysiological dormancy in seeds of two genera (Osmorhiza and Erythronium) with an Arcto-Tertiary distribution pattern\n
Run Code Online (Sandbox Code Playgroud)\n\n

变成

\n\n
Two types of morphophysiological dormancy in seeds of two genera (osmorhiza and erythronium) with an arcto-tertiary distribution pattern\n
Run Code Online (Sandbox Code Playgroud)\n\n

根据这个问题:如何设置对“句子大小写”的引用?,我应该从.csl文件中删除所有像text-case=. 问题是没有这样的行,但我的标题仍然被转换了。

\n\n

作为额外奖励,我还想知道如何将物种名称保留为斜体。

\n\n

Rmarkdown 文件

\n\n
---\ntitle: "Untitled"\noutput: html_document\nbibliography: refs.bib\ncsl: global-ecology-and-biogeography.csl\nlink-citations: …
Run Code Online (Sandbox Code Playgroud)

bibtex bibliography knitr r-markdown csl

5
推荐指数
1
解决办法
1137
查看次数

如何使用RMarkdown + knitr使用YAML元数据引用多位作者的论文?

我正在编写我的软件包的插图,我正在尝试包含一篇包含多位作者的论文作为参考,在代码的开头使用类似的东西:

---
references:
- id: doe2009
  title: A Method for Something
  author:
  - family: Doe
    given: John
  - family: Shepard
    given: Jane
  container-title: Some Journal
  volume: 11
  issue: 45
  page: 33-39
  type: article-journal
  issued:
    year: 2009
---
Run Code Online (Sandbox Code Playgroud)

问题是,我的引用如下:

Doe,John和Jane Shepard.2009."某种方法."一些期刊11(45):33-39.

第一作者有一种模式,第二作者有另一种模式.

如何将其更改为更一致的形式?此外,我正在尝试避免外部文件到我的包...有没有办法这样做而不使用外部csl?

对不起,这个问题可能听起来微不足道.我对CSL一无所知,这是我第一次尝试发布一个包.

r citations knitr r-markdown csl

3
推荐指数
1
解决办法
486
查看次数

rmarkdown:悬挂缩进引文

rmarkdown软件包使用biblatex和芝加哥作者日期样式作为默认值.

我想在引用中使用hang-indent,比如biblatex-chicago包.

David Sanson使用此建议:

\setlength{\parindent}{-0.2in}
\setlength{\leftskip}{0.2in}
\setlength{\parskip}{8pt}
Run Code Online (Sandbox Code Playgroud)

非常接近,但不幸的是它也缩进了第一个参考的第一行,这看起来不太好.关于如何使这项工作的任何想法?

biblatex r-markdown csl

3
推荐指数
1
解决办法
2213
查看次数

Mendeley 的标准 IEEE CSL 文件创建了不正确的参考书目

我一直在使用 Mendeley 的 Microsoft Word 插件来轻松引用我的 Mendeley 桌面库中的论文。

但是,我注意到参考书目/引文的 IEEE 格式在引用会议记录和论文方面是不正确的。

关于 IEEE 引文指南:http : //www.ieee.org/documents/ieeecitationref.pdf

它表明会议所在的城市应包括在会议论文的引用中。然而,Mendeley 的 IEEE CSL 文件不包括这个细节。

 <macro name="event">
<choose>
  <if type="paper-conference speech" match="any">
    <choose>
      <!-- Published Conference Paper -->
      <if variable="container-title">
        <group delimiter=", ">
          <group delimiter=" ">
            <text term="in"/>
            <text variable="container-title" font-style="italic"/>
          </group>
          <text variable="event-place"/>
        </group>
Run Code Online (Sandbox Code Playgroud)

应改为:

 <macro name="event">
<choose>
  <if type="paper-conference speech" match="any">
    <choose>
      <!-- Published Conference Paper -->
      <if variable="container-title">
        <group delimiter=", ">
          <group delimiter=" ">
            <text term="in"/>
            <text variable="container-title" font-style="italic"/>
          </group> …
Run Code Online (Sandbox Code Playgroud)

ieee mendeley csl

3
推荐指数
1
解决办法
2401
查看次数

是否可以将“等”改为斜体。中超风格?

我正在尝试创建一种 CSL 样式来自动引用研究论文(和实验室报告)。我的系认为其他地方的引文过于复杂,因此他们创建了自己的风格供学生使用。这种风格的要求之一是“等”。必须是斜体。然而,我似乎无法让中超做到这一点。这是可能吗?[X-来自学术界]

xml citations csl

3
推荐指数
1
解决办法
2623
查看次数

在参考文献中突出显示某个作者

我正在尝试使用jekyll和创建引用列表jekyll-scholar。有没有办法在CSL样式文件中突出显示(粗体)某个作者的名字?有没有一种更好的方法可以达到相同的效果而无需触碰CSL样式文件?

例如(从此处开始),这将是理想的:

Zelle RM,E.de Hulster,W.Kloezen,JT Pronk和AJA van Maris。2010。在工程酿酒酵母菌株的生物反应器分批培养中生产C4-二羧酸的关键工艺条件。应用 环境。微生物。76:744-750。

雅培DA,Zelle RM,JT Pronk和AJA van Maris。2009。酿酒酵母用于羧酸生产的代谢工程:现状和挑战。FEMS酵母库。9:1123-1136。

Zelle RM,E.de Hulster,WA van Winden,P.de Waard,C.Dijkema,AA Winkler,JA Geertman,JP van Dijken,JT Pronk和AJA van Maris。2008年。酿酒酵母生产苹果酸:丙酮酸羧化,草酰乙酸还原和苹果酸出口的工程设计。应用 环境。微生物。74:2766-2777。

xml citations jekyll csl

2
推荐指数
1
解决办法
150
查看次数

使用 csl 文件设置 Rmarkdown 参考书目中参考项目之间的间距

我目前正在尝试在使用 csl 文件时在 Rmarkdown 文件中正确格式化我的参考书目。

使用 natbib 时,引用项之间的间距工作正常,但是使用 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
Run Code Online (Sandbox Code Playgroud)

然后在 rmd 的末尾:


\```{=tex}
\newpage
\pagenumbering{gobble}
\```

# Literature {.unnumbered}
\singlespacing

Run Code Online (Sandbox Code Playgroud)

使用 csl 时,空间太小

csl间距

有了 natbib,空间就很好了

citation_package: natbib …

r bibtex xelatex r-markdown csl

2
推荐指数
1
解决办法
1030
查看次数