[R] Looking for knitr example for beginner (NO RStudio)

Yihui Xie xie at yihui.name
Thu Jul 18 20:43:33 CEST 2013


I'm not sure what your question really is. You do not have to use
RStudio, but it will be much easier to get started with RStudio,
because it does a lot of automatic conversion behind the scenes (e.g.
tex to PDF, markdown to HTML, ...). If you want a "pure" solution
without any text editor support, the answer is

library(knitr)
knit('your_input_file')

For example, knit('foo.Rnw') gives you foo.tex; if you are familiar
with LaTeX, you can mess with this foo.tex now (outside of R).

Minimal examples for different document formats are at
http://yihui.name/knitr/demo/minimal/ (you must have read this page),
and more examples at https://github.com/yihui/knitr-examples

If you are asking about the internals of knitr, "Luke, use the
source": https://github.com/yihui/knitr Or for a more comprehensive
introduction, see http://www.crcpress.com/product/isbn/9781482203530

Regards,
Yihui
--
Yihui Xie <xieyihui at gmail.com>
Phone: 206-667-4385 Web: http://yihui.name
Fred Hutchinson Cancer Research Center, Seattle


On Thu, Jul 18, 2013 at 11:13 AM, C W <tmrsg11 at gmail.com> wrote:
> Hi everyone,
>
> I am using package knitr, FIRST TIME.  I don't have access to RStudio.
>
> Read through Yihui's page, didn't find it helpful.  Stuck on terms
> Rnw, GFM (GitHub Flavored Markdown).  Never used Sweave, so the
> reference is not helping.
>
> Is there a simple step-by-step example WITHOUT RStudio?
>
> My question:
> What is the procedure?  The documentation explains the functions, but
> does not say how to operate between R and LaTex.
>
> Mike
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.



More information about the R-help mailing list