From p.dalgaard at biostat.ku.dk  Tue Oct 31 15:05:51 2006
From: p.dalgaard at biostat.ku.dk (Peter Dalgaard)
Date: 31 Oct 2006 15:05:51 +0100
Subject: [Rd] Syntax Error in Rcmd check on Windows
In-Reply-To: <84fc09fb0610310538v1d80061cr65553e95a63f1329@mail.gmail.com>
References: <84fc09fb0610310538v1d80061cr65553e95a63f1329@mail.gmail.com>
Message-ID: <x2iri0wpfk.fsf@viggo.kubism.ku.dk>

"Michael Hoehle" <michael.hoehle at gmail.com> writes:

> Dear R-developers,
> 
> I am currently developing an R package called RLadyBug. When
> developing under Linux "R CMD check ." works fine without a warning.
> However, when I do "Rcmd check ." under Windows (version 2.4.0 and
> earlier)  I get a ??syntax error" when checking the examples.
> 
> This puzzles me somewhat, because a manual source("RLadyBug-Ex.R") on
> Windows works fine. On the other hand, a "Rterm.exe --no-save <
> RLadyBug-Ex.R" in a command shell under Windows reproduces the error.
> My first guess was that the very long line was causing the problem,
> but when I open RLadyBug-Ex.R in Emacs, change the coding system from
> "undecided-dos" to "undecided-unix" and save the file "Rterm.exe
> --no-save < RLadyBug-Ex.R" works fine....
> 
> Does anybody has an idea what is causing the error and how to fix this?
> 
> Best regards,
> 
> Michael H?hle

....
> > sim.opts <- new( "LBOptions", seed=2006,
> +                             LBmodel=c( "gamma", "gamma", "gamma", FALSE ),
> +                             ignoreData=c( FALSE, FALSE, FALSE ),
> +                             initBeta =list( init=0.125,
> +                                         gamma=0.001, delta=0.001 ),
> +                             initBetaN=list( init=0.018,
> +                                         gamma=0.001, delta=0.001 ),
> +                             initIncu=list( asis=FALSE, const=FALSE,
> +                                     g=6.697, g.gamma=0.001, g.delta=0.001,
> +                                     d=0.84, d.gamma=0.001,d.delta=0.001 ),
> +                             initInf=list( 1.772, 0.001, 0.001,
> 0.123, 0.001, 0.001 ),
> +                             initDia=list( 149.126, 0.001, 0.001,
> +                                     8.737, 0.001, 0.001 ) )
> Error: syntax error in:
> "a=list( 149.126, 0.001, 0.001,
> "                                   8.737, 0.001, 0.001 ) )
> Execution halted
....

It's a longshot, but could some funny characters have crept in around
"initDia"?? (There's a way to open it in Hex from inside Emacs, isn't
there?)

-- 
   O__  ---- Peter Dalgaard             ??ster Farimagsgade 5, Entr.B
  c/ /'_ --- Dept. of Biostatistics     PO Box 2099, 1014 Cph. K
 (*) \(*) -- University of Copenhagen   Denmark          Ph:  (+45) 35327918
~~~~~~~~~~ - (p.dalgaard at biostat.ku.dk)                  FAX: (+45) 35327907




[Rd] Syntax Error in Rcmd check on Windows
Peter Dalgaard