From spencer.graves at pdf.com  Tue Dec 16 16:55:08 2008
From: spencer.graves at pdf.com (Spencer Graves)
Date: Tue, 16 Dec 2008 07:55:08 -0800
Subject: [Rd] "could not find function" error in "R CMD check"
Message-ID: <4947CF5C.7090702@pdf.com>

Hi, All: 

      What might cause "R CMD check" to report, "could not find 
function" for a function that has long been in the 'fda' package? 

      Both Jim Ramsay in Ottawa, Canada, and I in San Jose, CA, get this 
same error.  I replicated it with a fresh, anonymous checkout from 
R-Forge (svn checkout svn://svn.r-forge.r-project.org/svnroot/fda).  
With this, I did "R CMD build pkg", then "R CMD check fda_2.1.0.tar.gz", 
with the following result: 


D:\spencerg\statmtds\splines\fda\tmp\fda>R CMD check fda_2.1.0.tar.gz
* checking for working pdflatex ... OK
* using log directory 'D:/spencerg/statmtds/splines/fda/tmp/fda/fda.Rcheck'
* using R version 2.8.0 (2008-10-20)
* using session charset: ISO8859-1
* checking for file 'fda/DESCRIPTION' ... OK
* this is package 'fda' version '2.1.0'
* checking package name space information ... OK
* checking package dependencies ... OK
* checking if this is a source package ... OK
* checking for .dll and .exe files ... OK
* checking whether package 'fda' can be installed ... ERROR
Installation failed.
See 'D:/spencerg/statmtds/splines/fda/tmp/fda/fda.Rcheck/00install.out' 
for deta
ils.

     
####################################
      "00install.out" is as follows: 

####################################

installing R.css in D:/spencerg/statmtds/splines/fda/tmp/fda/fda.Rcheck


---------- Making package fda ------------
  adding build stamp to DESCRIPTION
  installing NAMESPACE file and metadata
  installing R files
  installing demos
  installing inst files
  installing data files
  preparing package fda for lazy loading
Loading required package: splines
Loading required package: zoo

Attaching package: 'zoo'


    The following object(s) are masked from package:base :

     as.Date.numeric

Error in basisfd(type = type, rangeval = rangeval, nbasis = nbasis, 
params = params,  :
  could not find function "use.proper.basis"
Error: unable to load R code in package 'fda'
Execution halted
make[2]: *** [lazyload] Error 1
make[1]: *** [all] Error 2
make: *** [pkg-fda] Error 2
*** Installation of fda failed ***

Removing 'D:/spencerg/statmtds/splines/fda/tmp/fda/fda.Rcheck/fda'


####################################

      Both "basisfd" and "use.proper.basis" have been in the "fda" 
package for years and have passed "R CMD check" many times.  I'm running 
Windows XP Pro and Jim is running Vista. 

      Any suggestions? 
      Thanks,
      Spencer Graves
   

 sessionInfo()
R version 2.8.0 (2008-10-20)
i386-pc-mingw32

locale:
LC_COLLATE=English_United States.1252;LC_CTYPE=English_United 
States.1252;LC_MONETARY=English_United 
States.1252;LC_NUMERIC=C;LC_TIME=English_United States.1252

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base    
 >



[Rd] "could not find function" error in "R CMD check"
Spencer Graves