pandoc

Using table caption on R markdown file using knitr to use in pandoc to convert to pdf

大兔子大兔子 提交于 2020-01-20 17:25:29
问题 I am wondering if it is possible to use the table captions like figure captions using knitr in .Rmd file ? I saw options for figure caption but I couldn't see the option for the table caption. I also want to remove the message such as "% latex table generated in R 2.15.2 by xtable 1.7-0 package % Wed Mar 06 15:02:11 2013" . I used X table to create the table: The sample code I used is as follows: ```{r table2, results='asis', message=FALSE} library(xtable) print(xtable(head(iris))) ``` The

How can I access un-rendered (markdown) content in Jekyll with liquid tags?

血红的双手。 提交于 2020-01-20 04:36:28
问题 From reading the documentation Jekyll's template data one might think that the way to access un-rendered content would be page.content ; but as far as I can tell, this is providing the content of the post as already rendered by the markdown parser. I need a solution that accesses the raw (original markdown) content directly, rather than simply trying to convert the html back to markdown. Background on use case My use case is the following: I use the pandoc plugin to render markdown for my

Can I specify command line options in a Pandoc Markdown document?

三世轮回 提交于 2020-01-17 06:43:43
问题 Sometimes, a *.md file requires (due to its content) a certain set of command line options regardless of the desired output format or of other, more optional command line options. E.g., when the document contains pandoc-fignos-style figure markup, --filter pandoc-fignos will always be required when wanting meaningful non-intermediate output. Instead of having to remember which of my Pandoc documents requires what options, can I declare arbitrary command line options within the file itself, e

How can I strip figures and table during a pandoc LaTeX to Word conversion?

狂风中的少年 提交于 2020-01-15 19:59:48
问题 I am trying to use pandoc to convert a thesis from latex to docx. In general, this works well with the following command: pandoc input.tex -f latex -t docx -s -o output.docx --bibliography references.bib --csl=mystyle.csl However, I have an additional requirement that I am unable to fulfill. I want the output to be stripped from any figures and tables that are included in the source files. Reading the pandoc documentation and related stackoverflow question has not helped me so far. Do you

RStudio Knitr failed to convert Rmd to PDF (Windows 7)

对着背影说爱祢 提交于 2020-01-15 09:37:22
问题 I wanted to use RStudio (Version 0.99.903) and knitr to convert a .Rmd file (please see below) to a PDF file. --- title: "test" output: pdf_document --- Roses are \textcolor{red}{red}, violets are \textcolor{blue}{blue}. When I run "Knit PDF" I got the following error message: processing file: test.Rmd output file: test.knit.md ! Undefined control sequence. l.87 Roses are \textcolor pandoc.exe: Error producing PDF Error: pandoc document conversion failed with error 43 In addition: Warning

LaTeX PDF with images from web in shinyapp

爱⌒轻易说出口 提交于 2020-01-14 08:22:28
问题 I used to be able to include images from URLs in PDF reports generated from shiny apps doing ![](url.com) . A few markdown versions later I get the following error: ! Unable to load picture or PDF file https://i0.wp.com/wptavern.com/wp-content/uploads/2016/07/stack-overflow.png?ssl=1 for the same code. Adding pandoc_args: ["--extract-media", "."] to the YAML downloads the imaged file locally but only works in local r-markdown files. How does shinyapp store local files and how to get the

NOTE or WARNING from package check when README.md includes images

丶灬走出姿态 提交于 2020-01-14 03:49:18
问题 I have a package with a README.Rmd that I pass to rmarkdown::render() producing README.md and a directory README_files , which contains images in README.md . This looks like the tree below. README_files is not a standard package directory, so if it isn't in .Rbuildignore , checking the package with R CMD check shows a note: * checking top-level files ... NOTE Non-standard file/directory found at top level: README_files But including the directory in .Rbuildignore leads to a warning, if and

Tableau-like grouped table in R for markdown

心不动则不痛 提交于 2020-01-12 20:32:51
问题 I frequently find myself calculating summary statistics in R using dplyr, then writing the result to csv and loading it into Tableau to generate a table because Tableau's tables are so simple and easy. I'd much rather generate the tables directly in R. Is there an easy solution for grouped tables in R? It's very easy to generate the data I would want: library(tidyr) library(dplyr) summary_table <- iris %>% gather(measure, value, -Species) %>% separate(measure, into=c("attribute", "dimension")

knitcitations gives pandoc-citeproc error

邮差的信 提交于 2020-01-12 08:01:09
问题 I have the following document, that I am trying to compile with Rstudio: --- output: word_document: pandoc_args: [ "--biblio", "references.bib" ] --- ```{r} library("knitcitations") cleanbib() ``` This is a citation citet("10.1098/rspb.2013.1372"): ```{r} citet("10.1098/rspb.2013.1372") ``` ```{r} write.bibtex(file="references.bib") ``` ```{r} summary(cars) ``` When I run knit, it compiles the .md file, but pandoc gives an error: processing file: toy.Rmd |...................... | 33% ordinary

pandoc document conversion failed with error 127

99封情书 提交于 2020-01-11 08:27:28
问题 I'm not sure how to make a reproducible example of this, but I'm curious to hear if anyone else has encountered this problem. I have an R Markdown file hosted via shiny server on an EC2 instance running Ubuntu. Everything was working fine for days and now suddenly I get the following error when I try to view the document in the browser: pandoc document conversion failed with error 127 I'm not converting to pdf, haven't pushed any changes, and it was working a few hours ago. I'm not finding