What happened might be that your vacation took too long. The encoding
argument was introduced in R 2.13.1 (July last year). Nothing has
changed in your Rnw document, but things have always been changing in
R, so the best thing to do is to check out help(Sweave).

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 Tue, Sep 4, 2012 at 7:02 PM, Shi, Tao <shida...@yahoo.com> wrote:
>
>
> Hi list,
>
> I was running Sweave on one of my .rnw file.  Everything was fine, until I 
> came back from the vacation.  Nothing changed (at least to my knowledge), but 
> now I have this problem:
>
>>     Sweave("myfile.rnw")
> Error: ‘COLO001final.rnw’ is not ASCII and does not declare an encoding
>
>
> After snooping around on the web, I found this solution:
>
>> Sweave("myfile.rnw", encoding="utf8")
>
> Now everything works fine.
>
> Could somebody explain to me what happened?  Why I need to specify the 
> "encoding" now for it to work?  What has changed (beyond my knowledge) in my 
> computer that is causing this error?
>
> I'm running R 2.15.1 on WinXP.
>
> Thanks!
>
> Tao
>
> ______________________________________________
> 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.

______________________________________________
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.

Reply via email to