[Rd] example fails during R CMD CHECK but works interactively?

Dirk Eddelbuettel edd at debian.org
Fri May 15 14:47:29 CEST 2015


On 15 May 2015 at 07:13, Hadley Wickham wrote:
| Make the example print out Sys.getenv() and then manually inspect?

On the systems I use    system("env")     is more efficient as it gets you
all at once. 
 
| Otherwise, you'll need to debug the code by adding print statements.
| Something clearly is not as you expect, so you need carefully
| empirically verify your assumptions about the inputs to and
| environment of the function.

Exactly. No magic here, just plainstaken debugging.

As an old ~/.signature of mine said: "In theory, theory and practice are the
same. In practie, they are not."  Assumptions are good.  We all get a good
laugh out of them after the fact.

Dirk

-- 
http://dirk.eddelbuettel.com | @eddelbuettel | edd at debian.org



More information about the R-devel mailing list