Dear R-users,
I am confused about defining S3 methods when objects or methods involve several dots. Here is my problem. Package coda defines the following two generic methods: as.mcmc(x,...) as.mcmc.list(x,...) I want to add an S3 method for the second method for my object of class twDEMC as.mcmc.list.twDEMC <- function(x,...) R CMD check then warns: * checking S3 generic/method consistency ... WARNING as.mcmc: function(x) as.mcmc.list.twDEMC: function(x, maxLength, thin, start, ...) See section 'Generic functions and methods' of the 'Writing R Extensions' manual. I also tried to use setMethodS3 from R.oo package: setMethodS3("as.mcmc.list","twDEMC", function( x, ...){}) I also added "S3method(as.mcmc.list,twDEMC)" to the NAMESPACE file. However, R CMD check still issues the warning. How do I tell R (or check??) what is the generic and what the class? (using Windows XP, R version 2.10.1) Best regards Thomas Wutzler ______________________________________________ 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.