[texworks] Sweave support
murdoch.duncan at gmail.com
Thu Oct 28 18:23:48 CEST 2010
On 28/10/2010 10:38 AM, Stephen Eglen wrote:
> Has anyone got support for Sweave files in texworks under Windows?
I wrote up some instructions on this for our students. You can read the
(it's the last tutorial listed). I haven't used it much myself, so
there may be errors or omissions. (I just noticed one:
it talks about the previewer Yap rather than the Texworks previewer.)
> (Sweave is a way of combining R code within latex. See e.g.
> for an example file. R code is included within chunks using
> R code here
> Together with the instructions on
> we can get the Sweave document compiled into a .tex file. One problem
> on windows however is that when 'estimate.Rnw' is loaded, texworks
> called the file 'estimate.Rnw.tex'. This confuses latex and Sweave
> (when the Sweave is generating figures, the figures have strange
> extensions that latex does not like.)
I haven't seen this. Are you sure the name changed when you loaded it,
not when you created the file? Windows hides extensions by default.
(You should turn off the hiding; it's one of the Explorer options, but I
forget how you get to it in current Windows releases.)
> Strangely though on linux, (ubuntu 10.10), loading estimate.Rnw into
> texworks does not add the .tex suffix.
> Best wishes, Stephen Eglen
More information about the texworks