[R] R CMD check, undoc and package checking

Kurt Hornik Kurt.Hornik at ci.tuwien.ac.at
Sun Nov 11 01:18:07 CET 2001


>>>>> "David Kane writes:

> As cool and wonderful as the package checking tools for R are, I
> sometimes am stymied when trying to track down a problem. For example,
> I occasionally see error messages when running R CMD check like the
> following:

> [...]
> * checking Rd files ... OK
> * checking for undocumented objects ... ERROR
> *   in parse(file, n, text, prompt) : syntax error on line 932
> *  in undoc(dir = "/home/a296180/tmp/pyri.port") :

> ...

One can never be defensive enough :-)

In R 1.3.1 I had already wrapped code loading parts of documentation
objects inside try() which gives much nicer error messages (telling you
in which documentation object, i.e. Rd file, the problem occurred).

But of course one should also say that loading the package R code failed
in case it did.  Done now in R-devel.  Thanks for spotting this.

> ...

> Question 3: Am I missing something? Is there some methodology that I
> should be following which would have made it much easier to discover
> the missing comma?

Once you know that the problem is in the package R code you can easily
start R and try to load the package: this will tell you where the
problem occurred.

One could maybe have a simple test in R CMD check which verifies that
the package can not only be installed but also loaded.  Will think about
this.

Best,
-k
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._



More information about the R-help mailing list