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

2013-07-18 Thread Yihui Xie
All your questions are answered by the knitr book in my first reply, which introduces knitr in a systematic manner. For the web pages, I have tried my best, and nobody can make everybody happy. I do not understand why you do not understand Rnw and markdown, and I do not quite believe a person who u

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

2013-07-18 Thread Yixuan Qiu
Hi Mike, As long as you have access to some user folder, you can download a non-install version of RStudio. Go to the page http://www.rstudio.com/ide/download/desktop and select "Show zip/tarball downloads", download, extract, and run. Do believe Yihui that running an example using RStudio saves yo

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

2013-07-18 Thread C W
Hi, @Yihui When I am using a public computer, say university computer lab or financial company. I do not have control what to install. I'm also very happy with R editor on OS X, it integrates with Mac well. As for my Mac Air, I am keeping installation to the minimal. There are a lot links on yo

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

2013-07-18 Thread Simon Zehnder
Hi Mike, if you browse the folders, you find always the Rscript binary (the executable) under /Library/Frameworks/R.framework/Versions/.../Resources/Rscript. Do not forget to give your tex file the extension .Rnw! Then surround each Rcode with <>= Here your r code as you do it in the R shell .

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

2013-07-18 Thread Yihui Xie
I recommend RStudio not because I want to promote it in any sense, but because of the fact that it has the best support for Rnw/knitr at the moment, and it will save you a lot of headache to get started. It seems you just do not believe me, and insist on going through all the low-level configuratio

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

2013-07-18 Thread Berend Hasselman
On 18-07-2013, at 22:22, C W wrote: > Thanks, Simon. I would never figured it out! > > I apologize if I sound frustrated, because I am. > > @package author: you have a great package, but I think a lot of the > directions are hand waving. For the newbies, this leads to more > confusion. > >

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

2013-07-18 Thread C W
Thanks, Simon. I would never figured it out! I apologize if I sound frustrated, because I am. @package author: you have a great package, but I think a lot of the directions are hand waving. For the newbies, this leads to more confusion. @Berend: I am using OS X. Mike On Thu, Jul 18, 2013 at

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

2013-07-18 Thread Berend Hasselman
On 18-07-2013, at 22:09, C W wrote: > http://tex.stackexchange.com/questions/85154/knitr-with-texworks/85165#85165 > > In step 3: "add the executable file (step 3)". > > What is the executable file? Locate package knitr directory path in R? > >From the window: Executable ==> Program. So th

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

2013-07-18 Thread Simon Zehnder
The executable is in case of knitr always Rscript. On a mac it is simply Rscript on windows it is Rscript.exe. This should be on your PATH. If you are not sure, open the Mac Terminal and type Rscript --version. If it does not say "Command not found" all is fine. Best Simon On Jul 18, 2013, at

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

2013-07-18 Thread C W
http://tex.stackexchange.com/questions/85154/knitr-with-texworks/85165#85165 In step 3: "add the executable file (step 3)". What is the executable file? Locate package knitr directory path in R? Mike On Thu, Jul 18, 2013 at 3:56 PM, C W wrote: > Actually, I see it at the bottom. Sorry! > > O

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

2013-07-18 Thread C W
Actually, I see it at the bottom. Sorry! On Thu, Jul 18, 2013 at 3:44 PM, C W wrote: > Hi Simon, > I am on OS X Lion, I have TeXworks, I don't have knitr as an option. > > How do I install that into TeXworks? Seems like I have to something > in terminal? > > Mike > > On Thu, Jul 18, 2013 at 3:3

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

2013-07-18 Thread C W
Hi Simon, I am on OS X Lion, I have TeXworks, I don't have knitr as an option. How do I install that into TeXworks? Seems like I have to something in terminal? Mike On Thu, Jul 18, 2013 at 3:31 PM, Simon Zehnder wrote: > Hi Mike, > > I found my way with this little blog: http://yihui.name/knit

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

2013-07-18 Thread Simon Zehnder
Hi Mike, I found my way with this little blog: http://yihui.name/knitr/demo/editors/ The .Rnw files are created very well in a Latex editor. Everything else can be easily googled. The command via knitr::knit2pdf works very fine if you use the chunks. If you are trying to compile an Rtex file, t

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

2013-07-18 Thread C W
How do you create a .Rnw file, in R or LaTex? I don't think any tutorial mentions it. btw, I am very new to the terms like markdown, so I don't understand "markdown to HTML". I am reading here http://biostat.mc.vanderbilt.edu/wiki/Main/KnitrHowto that you need to compile at terminal. I do not k

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

2013-07-18 Thread Yihui Xie
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,

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

2013-07-18 Thread C W
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?