【问题标题】:Bookdown/rmarkdown: "Could not find data file templates/--number-sections.latex Error: pandoc document conversion failed with error 97"Bookdown/rmarkdown:“找不到数据文件模板/--number-sections.latex 错误:pandoc 文档转换失败,错误 97”
【发布时间】:2020-04-07 10:45:38
【问题描述】:

关注:render_book("index.Rmd") 我收到了与三部分表相关的另一个错误: LaTeX Error: Environment ThreePartTable undefined 我应用了那里建议的解决方案(remotes::install_github('rstudio/rmarkdown'))。现在我有这个错误: “找不到数据文件模板/--number-sections.latex 错误:pandoc 文档转换失败,错误 97"

我的 index.Rmd 看起来像这样:

title: "Figures and Tables"
author: "name"
date: "`r Sys.Date()`"

output:
  bookdown::pdf_book:
    includes:
      in_header: preamble.tex
    keep_tex: yes
    citation_package: natbib
fontsize: 12pt
classoption: oneside
linestretch: 2
documentclass: book
bibliography: "bibs.bib"
biblio-style: "apalike"
geometry: "left=1.5in, right=1in, top=1in, bottom=1in"
---

preamble.tex 有:

\usepackage[none]{hyphenat}
\usepackage{booktabs}
\pagestyle{plain}
\raggedbottom 

虽然render_book("index.Rmd") 不会生成 pdf 并给我这个 pandoc 错误,但它成功地生成了一个合并的降价文件“FiguresTables.Rmd”。当我尝试编织它工作的合并文件时,它确实会生成 pdf。我只是无法弄清楚为什么我无法从render_book("index.Rmd") 生成 pdf。

【问题讨论】:

    标签: r-markdown pandoc bookdown


    【解决方案1】:

    没关系!写下这个问题让我想到了一个答案。我只是从 cran 存储库而不是 github 重新安装了 r-markdown 并再次尝试。现在它工作正常。

    【讨论】:

      猜你喜欢
      • 2018-02-23
      • 1970-01-01
      • 1970-01-01
      • 2017-07-14
      • 2016-04-13
      • 2019-10-14
      • 2014-11-09
      • 2017-05-08
      • 2015-01-14
      相关资源
      最近更新 更多