Questions tagged [pander]

pander is a Pandoc writer in R.

Pander can convert various objects to markdown with various helpers functions and a generic S3 method, from which the most often used function (pandoc.table) returns data.frame or table like R objects in grid, simple, multi-line or pipe table syntax.

Beside the pander method the package also contains some helpers to act like brew˙with a robust cache and other added features (e.g. capturing and auto-styling images) and to transform literate reports to HTML/pdf/odt/docx directly with the help of Pandoc.

Questions tagged should also be tagged

151 questions
1
vote
1 answer

knitr treats markdown text as verbatim

I'm trying to create a pdf with a table using knitr and pander packages in R, but it appears that some of the text in my table is being misinterpreted as code, because the resulting document shows the text as verbatim when it shouldn't. Here is…
Mark Nielsen
  • 991
  • 2
  • 10
  • 28
1
vote
0 answers

pander using only necessary number of rows in splitted summaries? (eg. when having Factors)

Is there any way of having pander using only the necessary amount of rows in splitted summary-tables (instead of always using the maximum number of rows)? This issue arises when there is a summary of a data.frame having for example numeric and…
Julian
  • 741
  • 8
  • 19
1
vote
0 answers

pander on aov in knitr does not print?

I'm trying to print the outcome of an anova like so: library(pander) m.aov = aov(Sepal.Width ~ Species * Sepal.Length, iris) pander(m.aov, split.table=Inf) and I get this as expected if I type it into the…
mathematical.coffee
  • 55,977
  • 11
  • 154
  • 194
1
vote
1 answer

Tables with column- and row-percentages using pander and CrossTable?

I am trying to generate reports with knitr and pander.To display row- or column-percentages in a table I would like to use the CrossTable() function and get rid of values of Chi-square contribution and the table total. Here is an example: ```{r} x…
maller
  • 229
  • 2
  • 4
  • 14
1
vote
1 answer

supressing table of contents in pander package

This is a question about the R packager "pander" I am using the live report generation feature of pander. I find this a useful, minimal way to get selected R results into a readable and sharable document. Whenever it exports the report to an html…
1
vote
1 answer

R: Pander sink stack full when printing summary lm

I am in the middle of generating a HTML report in Rstudio via pandoc for a collaborator. However pander is hitting the sink limit in R when trying to generate the output for the following summary of a lm() object. My R instance: version …
nfaux
  • 13
  • 4
1
vote
2 answers

how do you convert a data frame to a table to send as an email body

I have this data frame: library(sendmailR) library(pander) dput(s) structure(list(Description = c("ServerA", "ServerB", "ServerC", "ServerD", "ServerE", "ServerF"), Value = c("2", "2", "100", "100", "80", "20")), .Names = c("Description",…
user1471980
  • 10,127
  • 48
  • 136
  • 235
1
vote
0 answers

How do I add multidimensional tables using Pander?

I'm trying to add a 3D table to a .docx report using Pander, specifically via Live report Generation: A=sample(LETTERS[1:5],100, rep=T) b=sample(letters[1:2],100, rep=T) numbers=sample(1:3,100,…
Jerubaal
  • 65
  • 1
  • 7
1
vote
1 answer

How to ouput text with long lines into tables via pandoc

I have got a simple table in R, a piece of which is included here for reproduction. I'm trying to make a table in HTML out of it via Rmarkdown, using the pander package's pandoc.table function. However, any long enough string gives me an Error in…
prabhasp
  • 528
  • 3
  • 18
1
vote
1 answer

I cannot figure out how to get R to recognize the Pander package

I am trying to get a R -> Docx workflow. I used the tutorial given here. The commands to setup your R system (which I used from the tutorial) are: install.packages('pander') library(knitr) knit2html("example.rmd") # installing/loading the…
FirstName LastName
  • 1,891
  • 5
  • 23
  • 37
0
votes
1 answer

Rmarkdown: table with cross-ref AND invisible borders?

I have writen a numbered equation (call it eq1) in Rmarkdown with bookdown::html_document2 output (for numbering and cross-ref) as follow: \begin{equation} a=b+c (\#eq:eq1) \end{equation} Then I would like to add a legend below this equation…
Edouard
  • 35
  • 3
0
votes
0 answers

Pander list indentation different between Quarto and Rmarkdown

This R code: pander::pander(list("1", "2", 3, c(1, 2))) renders a list that looks like this in an Rmarkdown file: and a list that looks like this in a Quarto file: How can I prevent the second indentation level in the quarto file?
Robin Donatello
  • 415
  • 3
  • 12
0
votes
1 answer

Landscape environment in R Code Chunk in R Markdown breaks plot print

I have a code chunk in an R Markdown file, that generates multiple ggplots in a for loop. The chunk (pseudo-code) is called like so: ```{r print_data, results='asis'} print.all.results() ``` Inside the print.all.results(), the ggplots are generated…
Dom42
  • 147
  • 11
0
votes
1 answer

pander function inside sapply in r

How we use pander() function inside a sapply() to knit a table into HTML/ word? Here is my code Data <- data.frame(A = sample(1:2,10,replace = TRUE), B = sample(1:3,10,replace = TRUE), C = sample(1:5,10,replace…
Rasin Rs
  • 11
  • 1
0
votes
0 answers

reformat ascii table in R with pander

I have the following problem... I want to paste this ascii table from R into a reporting software (GE Viewpoint Ultrasound Reporting Software) pander::pandoc.table(mpg[1:3, 1:3]) The resulting table looks like…
mdb_ftl
  • 423
  • 2
  • 14