search for: cachemetadata

Displaying 12 results from an estimated 12 matches for "cachemetadata".

2002 Oct 03
1
cacheMetaData in R-1.6.0
Hi, I upgraded to R-1.6.0 and I am facing the following error when loading a package I am working on. Error in mlistMetaName(f) : No way to associate a generic function with an object of class "NULL" Error in library(affy) : .First.lib failed This happen when I do cacheMetaData(as.environment(where)) in the .First.lib function Any hint ? L. -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in th...
2006 Apr 09
2
type converters not being saved to workspace
Any one can explain why this happens or any work arounds? > setClass('foo') [1] "foo" > setAs('foo', 'character', function(from) from) > showMethods('coerce') Function "coerce": from = "ANY", to = "array" from = "ANY", to = "call" from = "ANY", to = "character" from =
2006 Apr 09
2
type converters not being saved to workspace
Any one can explain why this happens or any work arounds? > setClass('foo') [1] "foo" > setAs('foo', 'character', function(from) from) > showMethods('coerce') Function "coerce": from = "ANY", to = "array" from = "ANY", to = "call" from = "ANY", to = "character" from =
2006 Oct 06
1
class unions?
the code below has me confused: setClassUnion("index", c("numeric", "character", "logical")) extends("numeric") # i don't see the class union library(Matrix) extends("numeric") # now i see the class union i am aware that the "Matrix" package separately defines the "index" class union. is it the case that
2001 Nov 13
1
Methods package: One of those strategy questions
...n from the .First.lib function in your package (ONLY needed if you have methods for primitives). The code needed is something like this (inside .First.lib, which gets a second argument "pkgname": where <- match(paste("package:", pkgname, sep=""), search()) cacheMetaData(as.environment(where)) (Extra calls to cacheMetaData shouldn't hurt, beyond a moderate bit of extra computation, so this should not be a disaster even after modifications to library()). John -- John M. Chambers jmc@bell-labs.com Bell Labs, Lucent Technologies office: (90...
2013 Oct 29
1
unloadNamespace, getPackageName and "Created a package name xxx " warning
...e done to get rid of these warnings, which I believe in the case "unloadNamespace" case are irrelevant. The stack of calls is: # where 3: sapply(where, getPackageName) # where 4: findClass(what, classWhere) # where 5: .removeSuperclassBackRefs(cl, cldef, searchWhere) # where 6: methods:::cacheMetaData(ns, FALSE, ns) # where 7: unloadNamespace(pkgname) So for instance: >findClass('data.frame', getNamespace('data.table')) generates a warning which once again seems irrelevant. On the top of my head, I could imagine adding an extra argument to getPackageName, say warning = TRUE,...
2006 Oct 11
1
dispatching on group generics with more than one formal
please see the code below. foo2 fails to dispatch correctly, but foo does fine. i have tried 'cacheMetaData(1)' and a number of different variants of 'cacheGenericsMetaData', on the possibility there is a caching issue. but i still can't sort it out. also one general question: does it really matter what's in the body of the function definition in a 'setGroupGeneric' ca...
2019 Jan 24
0
Possible setClassUnion Unloading Issue
...aker. I should not need to reload my package to check validity of something like 'character'. In my actual use case I had a class that contained 'character' among other things that I was checking with `validObject(..., complete=TRUE)`. I attach a patch that adds a cleanup step to `cacheMetaData` which is kicked off by the package unload process. I grant I'm not an expert in these matters and there could very well be an important use case where removing the references is undesirable. This brings us to the second issue: even if the first patch is undesirable, `validObject` fails while...
2014 Nov 25
0
problem with setGroupGeneric from package methods
...9] LC_ADDRESS=C LC_TELEPHONE=C [11] LC_MEASUREMENT=en_GB.UTF-8 LC_IDENTIFICATION=C attached base packages: [1] stats graphics grDevices utils datasets methods base > library(pctsData) In one of the cases when the package installs the problem seems to appear after cacheMetaData -> .updateMethodsInTable -> .updateMethodsInTable -> .setupMethodsTables in one of the recursive calls to updateMethodsInTable (the place is marked with !!! towards the end of the code below). At the time of the error in .setupMethodsTables(generic) 'generic' is NULL and gen...
2003 Feb 19
3
Rcmd check does not recognize formal generic function as code object
...package itself .First.lib <- function(libname, pkgname) { require(methods, quietly=TRUE) # Find what position in the search path this package is where <- match(paste("package:", pkgname, sep=""), search()) .initClassesandMethods(where) cacheMetaData(as.environment(where)) } ------------------------- end test.R ---------------------------------- ------------------------- myGenericFun.Rd ------------------------ \name{myGenericFun} \docType{methods} \alias{myGenericFun} \title{My Generic Function} \description{A simple example generic function....
2011 Mar 01
1
changes in recent R-devel revisions?
Hi, I have a BioC infra-structure package that works fine (I can build, check and load it successfully) on revision r53950. The very same package fails on r54591 with the error below: Error in loadNamespace(package, c(which.lib.loc, lib.loc), keep.source = keep.source) : cyclic name space dependency detected when loading ?oligoClasses?, already loading ?oligoClasses? I don't see anything
2006 Nov 03
1
Formal methods are not loaded from NAMESPACE in reloadedworkspace image
Dear R-Devel subscriber, as a follow up to my yesterday's email: I tested an analogous example with the S4-package "flexclust" by executing the following code: library(flexclust) example(cclust) cl After saving the work space and starting a new R process with the restored work space, the same behaviour (i.e., the methods pertinent to "flexclust" are not used, even after