0

I have a .Rmd file and I want to export it to a HTML file. But the tables look wrong. In Rstudio the table looks good:

enter image description here

But when I export it to HTML (or PDF, Word, clicking on 'Knit'), then the table is not displayed properly:

enter image description here

phez1
  • 1,477
  • 3
  • 14
  • 19

1 Answers1

2

Maybe you are looking for kable, which can output md table, and set the results option to asis.

```{r, results='asis'}
efficient <- mtcars[mtcars$mpg > 23,]
knitr::kable(efficient)
```
Consistency
  • 2,884
  • 15
  • 23