[R] Sweave files generating miktex errors
Duncan Murdoch
murdoch.duncan at gmail.com
Tue Jan 29 23:20:48 CET 2013
On 13-01-29 4:55 PM, Troy S wrote:
> Duncan,
> Copying all 3 sty files to my working directory solved the problem. I'm
> still curious why this was necessary in my new install. Duncan, many
> thanks!
You do realize that you have now done a Very Bad Thing, I hope.
Duncan Murdoch
>
> Troy
>
> On Tue, Jan 29, 2013 at 10:58 AM, Duncan Murdoch
> <murdoch.duncan at gmail.com <mailto:murdoch.duncan at gmail.com>> wrote:
>
> On 29/01/2013 1:37 PM, Troy S wrote:
>
> Dear useRs--
>
> I have been using Sweave with miktex for years, but on a new
> install on
> Windows XP, miktex seems to be hung up on single quotes. See
> example below.
>
> Digging through stackexchange, I found using
> \usepackage[noae]{Sweave} in
> the tex file solved the problem. My questions are:
>
> --Why would this happen? I have the ae package installed.
>
> --If inserting [noae] is the solution, how do I have this done
> by Sweave?
>
> I'll start with the error messages followed by the tex file
> outputted by
> Sweave.
>
> Any help, please?\
>
>
> I don't know if this is the cause of your problem, but you are doing
> one Bad Thing: you have a copy of Sweave.sty in the same directory
> as your document. This is Bad because it is very easy to end up
> with Sweave.sty from R version X while using Sweave in R version Y,
> where X != Y. You should leave Sweave.sty where it is in the R
> installation, and use
>
> R CMD Sweave --pdf testsweave.Rnw
>
> (or one of the many equivalents) to process it.
>
> Duncan Murdoch
>
>
> Troy
> >
> This is pdfTeX, Version 3.1415926-2.4-1.40.13 (MiKTeX 2.9)
> entering extended mode
> ("C:\Documents and Settings\v\My Documents\testsweave.tex"
> LaTeX2e <2011/06/27>
> Babel <v3.8m> and hyphenation patterns for english, afrikaans,
> ancientgreek, ar
> abic, armenian, assamese, basque, bengali, bokmal, bulgarian,
> catalan,
> coptic,
> croatian, czech, danish, dutch, esperanto, estonian, farsi, finnish,
> french, ga
> lician, german, german-x-2012-05-30, greek, gujarati, hindi,
> hungarian,
> iceland
> ic, indonesian, interlingua, irish, italian, kannada, kurmanji,
> latin,
> latvian,
> lithuanian, malayalam, marathi, mongolian, mongolianlmc,
> monogreek,
> ngerman, n
> german-x-2012-05-30, nynorsk, oriya, panjabi, pinyin, polish,
> portuguese,
> roman
> ian, russian, sanskrit, serbian, slovak, slovenian, spanish,
> swedish,
> swissgerm
> an, tamil, telugu, turkish, turkmen, ukenglish, ukrainian,
> uppersorbian,
> usengl
> ishmax, welsh, loaded.
> (c:\miktex2.9.4757\tex\latex\
> base\article.cls
> Document Class: article 2007/10/19 v1.4h Standard LaTeX document
> class
> (c:\miktex2.9.4757\tex\latex\__base\size10.clo))
> ("C:\Documents and Settings\v\My Documents\Sweave.sty"
> (c:\miktex2.9.4757\tex\latex\__base\ifthen.sty)
> (c:\miktex2.9.4757\tex\latex\__graphics\graphicx.sty
> (c:\miktex2.9.4757\tex\latex\__graphics\keyval.sty)
> (c:\miktex2.9.4757\tex\latex\__graphics\graphics.sty
> (c:\miktex2.9.4757\tex\latex\__graphics\trig.sty)
> (c:\miktex2.9.4757\tex\latex\__00miktex\graphics.cfg)
> (c:\miktex2.9.4757\tex\latex\__pdftex-def\pdftex.def
> (c:\miktex2.9.4757\tex\__generic\oberdiek\infwarerr.__sty)
> (c:\miktex2.9.4757\tex\__generic\oberdiek\ltxcmds.sty))__))
> (c:\miktex2.9.4757\tex\latex\__fancyvrb\fancyvrb.sty
> Style option: `fancyvrb' v2.7a, with DG/SPQR fixes, and
> firstline=lastline
> fix
> <2008/02/07> (tvz))
> (c:\miktex2.9.4757\tex\latex\__upquote\upquote.sty)
> (c:\miktex2.9.4757\tex\latex\__base\fontenc.sty
> (c:\miktex2.9.4757\tex\latex\__base\t1enc.def))
> (c:\miktex2.9.4757\tex\latex\__ae\ae.sty
> (c:\miktex2.9.4757\tex\latex\__base\fontenc.sty
> (c:\miktex2.9.4757\tex\latex\__base\t1enc.def)
> (c:\miktex2.9.4757\tex\latex\__ae\t1aer.fd))))
> ("C:\Documents and Settings\v\My Documents\testsweave.aux")
> (c:\miktex2.9.4757\tex\__context\base\supp-pdf.mkii
> [Loading MPS to PDF converter (version 2006.09.02).]
> ) (c:\miktex2.9.4757\tex\latex\__ae\t1aett.fd)
> ! Undefined control sequence.
> <argument> + V1=c('
> a','b','b','a','c','c','d','a'__),
> l.14 + V1=c('a','b','b','a','c','c','__d','a'),
>
> \documentclass{article}
> \usepackage{Sweave}
> \begin{document}
> This is a test.
> \begin{Schunk}
> \begin{Sinput}
> > (x <- 1+2)
> \end{Sinput}
> \begin{Soutput}
> [1] 3
> \end{Soutput}
> \begin{Sinput}
> > test <- data.frame(
> + V1=c('a','b','b','a','c','c','__d','a'),
> + V27=c('1-oct-2004', '3-jan-2005','4-jan-2005','30-__jan-2004',
> + '12-oct-2012','13-sep-2012', '1-jan-1999', '31-dec-2004'),
> + V24=letters[1:8])
> \end{Sinput}
> \end{Schunk}
>
> \end{document}
>
> [[alternative HTML version deleted]]
>
> ________________________________________________
> R-help at r-project.org <mailto:R-help at r-project.org> mailing list
> https://stat.ethz.ch/mailman/__listinfo/r-help
> <https://stat.ethz.ch/mailman/listinfo/r-help>
> PLEASE do read the posting guide
> http://www.R-project.org/__posting-guide.html
> <http://www.R-project.org/posting-guide.html>
> and provide commented, minimal, self-contained, reproducible code.
>
>
>
More information about the R-help
mailing list