On 08/08/2012 10:58 AM, Jonas Hal wrote:
I am using win xp, R 2.15.0 and texi2dvi from the tools package.

I'd suggest checking the encoding of your file (if I use latin1, I get an NA like you did). If that's not it, then you should upgrade to the latest release, or to the current patched version.

Duncan Murdoch


Regards
Jonas

-----Oprindelig meddelelse-----
Fra: Duncan Murdoch [mailto:murdoch.dun...@gmail.com]
Sendt: 8. august 2012 16:43
Til: Jonas Hal
Cc: r-help@r-project.org
Emne: Re: [R] sweave problem with special danish characters

On 08/08/2012 6:15 AM, Jonas Hal wrote:
> Dear all,
>
> I use Sweave to create my reports. my pdf output contains only NA's whenever 
my text contains special Danish characters like ø, ø and å. I have upgraded R from 
2.13 to 2.15 and the scripts worked fine under R 2.13.
>
> Sweave("Test.Rnw", encoding = "utf8")
> texi2dvi("Test.tex", pdf = TRUE)
>
> %"Test.Rnw"
> \documentclass{article}
> \usepackage [danish]{babel}
> \usepackage[utf8]{inputenc}
> \begin{document}
> This is a test that works
> \end{document}
>
> %"Test.Rnw"
> \documentclass{article}
> \usepackage [danish]{babel}
> \usepackage[utf8]{inputenc}
> \begin{document}
> This doesn't æ ø å and pdf document only contains NA \end{document}
>
> Any suggestions?

I think you need to give more information.  I just tried it in 2.15.1 patched 
on Windows 32 bit, and it worked fine.  What OS are you using?
Is the file really encoded using utf-8?  What version of R were you using 
(there's no such thing as 2.15)?  Where did you find the texi2dvi function?  
(There's one in the tools package, but it isn't normally attached.  Are you 
using that one, or your own?)

Duncan Murdoch
_________________________________________________________________________________________________________________________________________
BRFkredit sender e-mails og vedhæftede dokumenter i ikke-krypteret form. Hvis 
du ikke ønsker at modtage oplysninger fra BRFkredit pr. e-mail, beder vi dig 
meddele os det via brev eller e-mail. Denne e-mail kan indeholde fortrolig 
information. Hvis du modtager e-mailen ved en fejl, beder vi dig informere os 
om det hurtigst muligt. Samtidig beder vi dig slette e-mailen uden at 
videresende eller kopiere indholdet.
_________________________________________________________________________________________________________________________________________

______________________________________________
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