[R] SWEAVE - a gentle introduction

Therneau, Terry M., Ph.D. therneau at mayo.edu
Wed Nov 18 14:56:42 CET 2015

As a digest reader I am late to the discussion, but let me toss in 2 further notes.

1. Three advantages of knitr over Sweave
   a. The book "Dynamic documents with R and knitr".  It is well written; sitting down for 
an evening with the first half (70 pages) is a pretty good way to learn the package.  The 
second half covers features you may or may not use over time.  My only complaint about the 
book is that it needs a longer index; I have had several cases of "I know I read about 
xxx, but where was it?".  But this is ameliorated by

   b. Good online resources: manuals, tutorials, and question/answer pairs on various lists.

   c. Ongoing support. Sweave is static.

2. Latex vs markdown  (knitr supports both)
   One can choose "latex style" or "markdown style" for writing your documents.  I know 
latex very well (I wrote my book using it) but recommend markdown to all others in my 
department.  The latter is about 1/3 the learning curve.  Markdown produces very nice 
output, latex goes the extra mile to produce true book quality.  But one rarely needs that 
extra polish, and even more rarely needs it enough to justify the extra learning cost.  I 
still use the latex form myself as it is not at all difficult to use --- once you learn it.

Terry Therneau

On 11/18/2015 05:00 AM, r-help-request at r-project.org wrote:
> I am looking for a gentle introduction to SWEAVE, and would appreciate recommendations.
> I have an R program that I want to run and have the output and plots in one document. I believe this can be accomplished with SWEAVE. Unfortunately I don't know HTML, but am willing to learn. . . as I said I need a gentle introduction to SWEAVE.
> Thank you,
> John

More information about the R-help mailing list