search for: genericfunct

Displaying 18 results from an estimated 18 matches for "genericfunct".

Did you mean: genericfunc
2005 Nov 14
1
Tidiest way of modifying S4 classes?
...ensible in this case. What does one make of this: > getClass(class(kinship:::plot.pedigree)) No Slots, prototype of class "function" Extends: "OptionalFunction", "PossibleMethod" Known Subclasses: Class "MethodDefinition", from data part Class "genericFunction", from data part Class "functionWithTrace", from data part Class "derivedDefaultMethod", by class "MethodDefinition" Class "MethodWithNext", by class "MethodDefinition" Class "SealedMethodDefinition", by class "MethodDefinitio...
2004 Jun 26
1
S4 group "Math", "getGroupMembers", "genericForPrimitive"
...ric(x@y); x }) tr1 <- new("track", x = 1:3, y = 1:3) tr1 ## are documented as belonging to group "Math" ## see ?"Math" ## but don't work log(tr1) log10(tr1) gamma(tr1) lgamma(tr1) ## are not generic and don't belong to any group! is("log", "genericFunction") is("log10", "genericFunction") is("gamma", "genericFunction") is("lgamma", "genericFunction") getGroup("log") getGroup("log10") getGroup("gamma") getGroup("lgamma") ## make this functions...
2012 Aug 22
1
loading both RPostgreSQL and RSQLite leads to problems
...('show') Function: show (package methods) object="ANY" object="classGeneratorFunction" object="classRepresentation" object="dbObjectId" object="envRefClass" object="function" (inherited from: object="ANY") object="genericFunction" object="genericFunctionWithTrace" object="MethodDefinition" object="MethodDefinitionWithTrace" object="MethodSelectionReport" object="MethodWithNext" object="MethodWithNextWithTrace" object="namedList" object="Objec...
2012 Apr 05
1
issue with base:::namespaceImportMethods
...generics <- c(generics, g) + packages <- c(packages, p) + } } if(g %in% vars && !exists(g, envir = self, inherits = FALSE)) { if(exists(g, envir = ns) && - methods:::is(get(g, envir = ns), "genericFunction")) + methods:::is(get(g, envir = ns), "genericFunction")) { allVars <- c(allVars, g) + generics <- c(generics, g) + packages <- c(packages, p) + } else { # should be primitive...
2013 Jan 23
3
Pasting a list of parameters into a function
I need to repeat a function many times, with differing parameters held constant across iterations. To accomplish this, I would like to create a list (or vector) of parameters, and then insert that list into the function. For example: q<-("l,a,b,s") genericfunction<-function(q){ } ###### The equivalent code would of course be genericfunction<-function(l,a,b,s){ } Any help or suggestions would be much appreciated. -- View this message in context: http://r.789695.n4.nabble.com/Pasting-a-list-of-parameters-into-a-function-tp4656445.html Sent from...
2003 Jul 09
2
Packages, generics, S3 and S4
...ERROR Running examples failed. Ignoring this (only for the time being), I now do 'make pkg-track', and encounter no errors. Loading the package, my 'examples' work fine. Returning to the ERROR, it is clear how this has come about. ls(.GlobalEnv) [1] "plotT" So the genericFunction object plotT resides in frame 1 i.e. .GlobalEnv. It gets deleted when cleanEx(env=.GlobalEnv) does its job in Rcmd CHECK. The other object defined in this package, plotTrack, is in frame 2: ls(2) [1] "plotTrack" I have tried unsuccessfully to put the genericFunction object plotT...
2014 Nov 25
0
problem with setGroupGeneric from package methods
...n(def)) { ## exclude a non-function of the same name as a primitive with methods (!) if(identical(environment(def), environment(fdef))) next # the methods are identical else if( is(fdef, "genericFunction")) { .assignOverBinding(f, fdef, env, FALSE) } } # else, go ahead to update primitive methods } else # either imported generic or a primitive fdef <-...
2019 Sep 16
1
Error: package or namespace load failed for ‘utils
...lib.loc <- > "<fill this according to your R install>" ns <- > loadNamespace(package, lib.loc) ``` > The code path goes through > `registerS3methods(nsInfo$S3methods, package, env)` and > there to: > ``` if (methods::is(genfun, "genericFunction")) ``` > The evaluation of `methods::is` reaches the line > triggering the error as `.identC(class1, class2)` and > `.identC(class2, "ANY")` both return `NA` and `NA || NA` > is not defined: > ``` >> if (NA || NA) { cat("here\n&q...
2006 Sep 04
1
setMethod("Summary")
...switch(.Generic, max = .Brob.max(...), stop(paste(.Generic, "not implemented yet ")) ) } ) but this gives an error from conformMethod(). [I've left the arguments to signature() unnamed because ? GenericFunctions says A signature is a named or unnamed vector of character strings. If named, the names must be formal argument names for the generic function. If 'signature' is unnamed, the default is to use the first 'length(signature)'...
2013 Aug 24
2
Correct NAMESPACE approach when writing an S3 method for a generic in another package
Dear List, In one of my packages I have an S3 method for the plot3d generic function from package rgl. I am trying to streamline my Depends entries but don't know how to have plot3d(foo) in the examples section for the plot3d method in my package, without rgl being in Depends. Note that I importFrom(rgl, plotd3d) and register my S3 method via S3Method() in the NAMESPACE. If rgl is not in
2019 Sep 08
6
Error: package or namespace load failed for ‘utils
Hi, When starting an embedded R I encounter the following issue under certain conditions: ``` Error: package or namespace load failed for ?utils? in if (.identC(class1, class2) || .identC(class2, "ANY")) TRUE else {: missing value where TRUE/FALSE needed ``` (more such errors for grDevices, graphics, and stats) And in the end: ``` Warning messages: 1: package ?utils? in
2006 Jan 03
1
lmer error message
Dear All, I have the following error message when I fitted lmer to a binary data with the "AGQ" option: Error in family$mu.eta(eta) : NAs are not allowed in subscripted assignments In addition: Warning message: IRLS iterations for PQL did not converge Any help? Thanks in advance, Abderrahim [[alternative HTML version deleted]]
2010 Feb 08
2
Error on start R in server
...imbalance in 'if', 99 then 97 Warning: stack imbalance in '<-', 84 then 85 Warning: stack imbalance in '{', 82 then 84 Warning: stack imbalance in 'if', 80 then 82 Traceback: 1: .getClassFromCache(Class, where) 2: getClassDef(cl) 3: methods:::is(genfun, "genericFunction") 4: registerS3methods(nsInfo$S3methods, package, env) 5: loadNamespace(package, c(which.lib.loc, lib.loc), keep.source = keep.source) 6: doTryCatch(return(expr), name, parentenv, handler) 7: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 8: tryCatchList(expr, classes, parentenv,...
2003 Jul 03
1
S4 method and S3 method with same name: potentially dangerous?
...ture("RSVMState","numeric", "missing"), function(object, newdata, ...) { cat("\nobj:\n"); print(object); cat("\n\nnewdata;\n");print(newdata);return();}) Creating a new generic function for "predict" [1] "predict" > predict genericFunction for "predict" defined from package "base" function (object, ...) standardGeneric("predict") <environment: 0x8e942a4> Methods may be defined for arguments: object > getMethods("predict") object = "ANY": function (object, ...) UseMethod...
2003 May 30
3
Missing 'getGroupMembers()'
Hi, I'm trying to write a method such that my own classes can be used with the groups like "Summary" and "Math", but when I tried to look for examples or just wanted to get an idea of which functions are the members of a group, I found out that the function "getGroupMembers" is not present... I couldn't find an alternative function, if there is one. Does
2018 Apr 23
0
R 3.5.0 is released
...a warning. * The list method of within() gains an option keepAttrs = FALSE for some speed-up. * system() and system2() now allow the specification of a maximum elapsed time ('timeout'). * debug() supports debugging of methods on any object of S4 class "genericFunction", including group generics. * Attempting to increase the length of a variable containing NULL using length()<- still has no effect on the target variable, but now triggers a warning. * type.convert() becomes a generic function, with additional methods that ope...
2018 Apr 23
0
R 3.5.0 is released
...a warning. * The list method of within() gains an option keepAttrs = FALSE for some speed-up. * system() and system2() now allow the specification of a maximum elapsed time ('timeout'). * debug() supports debugging of methods on any object of S4 class "genericFunction", including group generics. * Attempting to increase the length of a variable containing NULL using length()<- still has no effect on the target variable, but now triggers a warning. * type.convert() becomes a generic function, with additional methods that ope...
2002 Jul 11
1
dyn.load tcl/tk (PR#1774)
...xample BasicClasses text html latex BasicFunctions text html latex Classes text html latex EmptyMethodsList-class text html latex EnvironmentClass text html latex GenericFunctions text html latex LanguageClasses text html latex LinearMethodsList-class text html latex MethodDefinition-class text html latex MethodSupport text html latex MethodWithNext-class...