2

I am writing a paper using Rmarkdown v2 in Rstudio and exporting to PFD format. Inside the paper, I want to include a regression table that was generated by another software and saved to a Latex Document (.tex).

How do I do that?

I looked at the Rmarkdown v2 documentation and on-line but could not find any reference to this, probably because the idea is to use R all the way (which is not an option yet in my case)

USING: R version 3.1.1, RStudio 0.98.1017, Windows 7

LucasMation
  • 2,408
  • 2
  • 22
  • 45
  • Have you considered using Pandoc in RStudio? From the [RStudio blog](http://blog.rstudio.org/2014/06/18/r-markdown-v2): "...you can even embed raw LaTeX/HTML code in Markdown, and Pandoc is smart enough to process these raw fragments." – zhaoy Oct 29 '14 at 19:59
  • tks. From what I see in the documentation, Rmarkdown v2 is integrated with Pandoc, or runs it in the background. In any case, copying and pasting the Latex code inside the .tex file works (after deleting \begin{document} and \end{document}). But that creates a manual step, and the point was automating the process – LucasMation Oct 30 '14 at 11:49
  • Uninstall the software that does not give you the expected LaTeX output, and use one of the many choices in R: `xtable`, `knitr::kable()`, `pander`, and so on. – Yihui Xie Nov 10 '14 at 21:48

0 Answers0