found the solution:

v <- function(x, ...) UseMethod("v")

setMethod('v', signature(x='character'), function(x, ...) v.print(x, ...))
setMethod('v', signature(x='numeric'), function(x, ...) v.numeric(x, ...))

v.print <- function(x,y=x,z=x) print(paste(x,y,z))
v.numeric <- function(x,u=3*x) print(u*x)

examples:
v(1)
v('a')

The tab-key after typing 'v( gives:
x=
...
u=
y=
z=



--
View this message in context: 
http://r.789695.n4.nabble.com/generic-function-method-arguments-accessible-by-tab-key-tp4688793p4688859.html
Sent from the R help mailing list archive at Nabble.com.

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to