Skip to content
This repository has been archived by the owner on Apr 9, 2024. It is now read-only.

Tables generated from functions leave hyphens after dedoc #70

Open
shirdekel opened this issue Mar 27, 2020 · 0 comments
Open

Tables generated from functions leave hyphens after dedoc #70

shirdekel opened this issue Mar 27, 2020 · 0 comments

Comments

@shirdekel
Copy link

reprex.Rmd

YAML:

---
title: Reversible R Markdown Document
subtitle: Your subtitle
author: Your Name
date: Created `r Sys.Date()`
output:
  redoc::redoc:
    highlight_outputs: TRUE
    margins: 1 
    line_numbers: FALSE 
---

R code:

Table 1

```{r results = "asis"}
test <- data.frame(col1 = "text1", col2 = "text2")
papaja::apa_table(test)
```

Table 2

```{r results = "asis"}
pander::pandoc.table(test)
```

Table 3

---------------
 col1    col2  
------- -------
 text1   text2 
---------------

Output:

reprex.docx

Dedoc:

YAML:

---
title: Reversible R Markdown Document
subtitle: Your subtitle
author: Your Name
date: Created `r Sys.Date()`
output:
  redoc::redoc:
    highlight_outputs: yes
    margins: 1
    line_numbers: no
---

R code:

Table 1

```{r results = "asis"}
test <- data.frame(col1 = "text1", col2 = "text2")
papaja::apa_table(test)
```

 
  ------------------------- -------------------------
 

Table 2

```{r results = "asis"}
pander::pandoc.table(test)
```

 
  ------------------------- -------------------------
 

Table 3

  col1    col2
  ------- -------
  text1   text2

Tables generated from functions such as papaja::apa_table and pander::pandoc.table leave hyphens after dedoc, whereas a pandoc table written inline renders fine (albeit with some extra spaces on the left).


Session Info
Session info ─────────────────────────
 setting  value                       
 version  R version 3.5.3 (2019-03-11)
 os       macOS Mojave 10.14.6        
 system   x86_64, darwin15.6.0        
 ui       RStudio                     
 language (EN)                        
 collate  en_AU.UTF-8                 
 ctype    en_AU.UTF-8                 
 tz       Australia/Sydney            
 date     2020-03-27 

Pandoc version (get with rmarkdown::pandoc_version): 2.3.1

RStudio version (if applicable): 1.3.300

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant