Well, I do not think it is a good practice (in terms of reproducible research) to keep on running Sweave in the same R session, because your previous run and your current workspace could "pollute" your next run. To make sure a document compiles on its own, it is better always to start a new clean R session. If you run into speed issues (e.g. you have chunks which require intensive computing), you can consider using cache, which the knitr package has reasonably good support.
Regards, Yihui -- Yihui Xie <xieyi...@gmail.com> Phone: 515-294-2465 Web: http://yihui.name Department of Statistics, Iowa State University 2215 Snedecor Hall, Ames, IA On Thu, Apr 5, 2012 at 12:26 PM, Alexander Shenkin <ashen...@ufl.edu> wrote: > Yep, I'm using RStudio, and have used Tinn-R in the past. RStudio does > start a new R session when processing a sweave document via the RStudio > GUI. In my case, this presented a problem for the reasons I stated > before (i.e. that I need to run sweave in the main environment, not a > new one). Hence, I'm running Sweave from the command line, and > processing the tex doc via TeXworks (from MiKTeX). I sent the RStudio > team a feature request to add an option to be able to run Sweave in the > main environment (perhaps while maintaining the default of running it in > a separate environment). > > Allie > ______________________________________________ R-help@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.