0

So, despite my best efforts to get sweave working in RStudio, I cannot do it for the life of me. Trawling the webs, and even trying the answer to this question haven't helped.

OK. I'm trying to compile chapters of my supervisors book, but every time I hit Compile PDF, it bombs out with this error:

grDevices::pdf.options(useDingbats = FALSE); utils::Sweave('test.Rnw', encoding='ASCII') Writing to file test.tex Processing code chunks ... Error in RweaveLatexOptions(options) : invalid value for 'encoding' : ASCII Calls: -> -> RweaveLatexOptions Execution halted

Removing all the code, even pasting in the answer to the above-linked question have not helped. Whilst I have no doubt that it is a simple solution, I cannot find it. This is a fresh and clean install of RStudio - R and TexNic Centre both work fine.

Community
  • 1
  • 1
Albort
  • 177
  • 1
  • 11
  • Bizarrely, I got some a test document to compile in one window. Copy and pasted it into a different window and it came up with the same error. – Albort Feb 27 '13 at 11:08

1 Answers1

0

I've gotten this error in the past when I had stupid stuff like curly quotes vs. straight quotes in my file. This usually happens when I've copied some stuff out of a document and pasted it into the RStudio window. With that said, I'm not sure if that's what's wrong here, since you seem to have the same problem even if you use only the same code from that answer?

TARehman
  • 6,659
  • 3
  • 33
  • 60