search for: methodform

Displaying 6 results from an estimated 6 matches for "methodform".

2015 Jan 29
3
[Q] Get formal arguments of my implemented S4 method
...to evaluate the rhs. Here is a function that does the same sort of thing, and returns the standard formals for the generic if this method does not have nonstandard arguments. We should probably add a version of this function for 3.3.0, so user code doesn't have hacks around the current hack. methodFormals <- function(f, signature = character()) { fdef <- getGeneric(f) method <- selectMethod(fdef, signature) genFormals <- base::formals(fdef) b <- body(method) if(is(b, "{") && is(b[[2]], "<-") && identical(b[[2]][[2]], as.nam...
2015 Jan 29
2
[Q] Get formal arguments of my implemented S4 method
...nction that does the same sort of thing, and returns the > standard formals for the generic if this method does not have nonstandard > arguments. We should probably add a version of this function for 3.3.0, so > user code doesn't have hacks around the current hack. > > > > methodFormals <- function(f, signature = character()) { > > fdef <- getGeneric(f) > > method <- selectMethod(fdef, signature) > > genFormals <- base::formals(fdef) > > b <- body(method) > > if(is(b, "{") && is(b[[2]], "&lt...
2015 Jan 29
1
[Q] Get formal arguments of my implemented S4 method
...t does the same sort of thing, and returns the > standard formals for the generic if this method does not have nonstandard > arguments. We should probably add a version of this function for 3.3.0, so > user code doesn't have hacks around the current hack. > > > > > > methodFormals <- function(f, signature = character()) { > > > fdef <- getGeneric(f) > > > method <- selectMethod(fdef, signature) > > > genFormals <- base::formals(fdef) > > > b <- body(method) > > > if(is(b, "{") &&...
2015 Jan 29
0
[Q] Get formal arguments of my implemented S4 method
...s. > > Here is a function that does the same sort of thing, and returns the standard formals for the generic if this method does not have nonstandard arguments. We should probably add a version of this function for 3.3.0, so user code doesn't have hacks around the current hack. > > methodFormals <- function(f, signature = character()) { > fdef <- getGeneric(f) > method <- selectMethod(fdef, signature) > genFormals <- base::formals(fdef) > b <- body(method) > if(is(b, "{") && is(b[[2]], "<-") && iden...
2015 Jan 29
0
[Q] Get formal arguments of my implemented S4 method
...t; Here is a function that does the same sort of thing, and returns the standard formals for the generic if this method does not have nonstandard arguments. We should probably add a version of this function for 3.3.0, so user code doesn't have hacks around the current hack. > > > > methodFormals <- function(f, signature = character()) { > > fdef <- getGeneric(f) > > method <- selectMethod(fdef, signature) > > genFormals <- base::formals(fdef) > > b <- body(method) > > if(is(b, "{") && is(b[[2]], "&lt...
2015 Jan 28
2
[Q] Get formal arguments of my implemented S4 method
I'm attempting to reflect the information for use with corresponding fields in GUI (in a different package), to provide default values, argname as key for UI label lookups, etc. So I want something much more like the formals of the implementation: { "object", "method": c("median", "vs", "tukey"),