[Bioc-devel] generics from Biobase not found during package installation

Robert Gentleman rgentlem at fhcrc.org
Fri Oct 21 15:49:57 CEST 2005


Hi Florian,
   I suspect that the problem is that you will need to make use of 
.onLoad. One of the tricky bits with the "save image" technology is that 
any methods that you want to associate with generics from another 
package must have the setMethod code run each time the package is loaded 
(or attached). For any generics you define we save time by doing the 
association at package build time (because it cannot change).

   There is one example in Biobase (and I think some more substantial 
ones in iSPlot),

   Robert


Florian Hahne wrote:
> Hi everyone,
> with the new bioC release I encounter a strange problem in my prada package:
> I'm using some of the generics from Biobase (e.g. exprs, pData, 
> phenoData, description) to build methods for my own objects of class 
> cytoFrame (which describe data from FACS measurements).
> e.g.
> setMethod("description", signature="cytoFrame", 
> definition=function(object) object at description, valueClass="character")
> 
> This used to work fine with all recent bioC releases, but now I get the 
> following error when trying to install prada (and the same thing happens 
> on the build test machines in Seattle):
> 
> * Installing *source* package 'prada' ...
> ** R
> ** inst
> ** save image
> Loading required package: Biobase
> Loading required package: tools
> 
> Welcome to Bioconductor
> 
>         Vignettes contain introductory material.
>         To view, simply type 'openVignette()' or start with 'help(Biobase)'.
>         For details on reading vignettes, see the openVignette help page.
> 
> Loading required package: RColorBrewer
> Loading required package: grid
> KernSmooth 2.22 installed
> Copyright M. P. Wand 1997
> 
> ** preparing package for lazy loading
> KernSmooth 2.22 installed
> Copyright M. P. Wand 1997
> Error in methods:::mlistMetaName(mi, ns) :
>         the methods object name for 'description' must include the name 
> of the package that contains the generic function, but there is no 
> generic function of this name
> Execution halted
> ERROR: lazy loading failed for package 'prada'
> 
> Obviously R can't find the generics from Biobase although it is 
> attached. As a quick fix I tried to redefine those "missing" generics in 
> my own package. By doing so I get rid of the error message during 
> installation but I also break all functionality from Biobase. When 
> adding require(Biobase) in my R code before setting the new methods this 
> evaluates to TRUE but isGeneric(description) evaluates to FALSE during 
> installation.
> When starting R interactively an after attaching Biobase I can set my 
> new methods without any problem simply by pasting in the code.
> 
> Does anybody have any idea what might be going wrong here?
> 
> My system setup is i686-pc-linux-gnu running with R 2.2.0 release and a 
> fresh installation of bioC 1.7 release (Biobase 1.8.0, prada 1.6.1)
> 
> Thank's in advance,
> Florian
> 
> _______________________________________________
> Bioc-devel at stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/bioc-devel
> 

-- 
Robert Gentleman, PhD
Program in Computational Biology
Division of Public Health Sciences
Fred Hutchinson Cancer Research Center
1100 Fairview Ave. N, M2-B876
PO Box 19024
Seattle, Washington 98109-1024
206-667-7700
rgentlem at fhcrc.org



More information about the Bioc-devel mailing list