Skip to content
Prev 47920 / 63424 Next

Conflicting definitions for function redefined as S4 generics

I fully agree, Michael, that this would be a great thing to have! I have 
often wondered why R and the standard packages are still sticking so 
much to the old-style S3 flavor though S4 is part of standard R. I 
acknowledge that backward compatibility is important, but, as far as I 
got it, redefining a function or S3 generic as an S4 generic should not 
harm existing functionality (if done properly). If it turns out not to 
be a good option to do this in the base package, why not as part of the 
methods package? That will leave existing functionality of base 
unchanged and will provide a clean situation to all users/packages using S4.

This should not create a compatibility problem on the Bioconductor side 
either, since Bioconductor releases are explicitly bound to specific R 
versions. Once again: I fully support this idea (not only for sort(), 
but also for a wide range of other functions), though, not being an R 
core team member, I do not really feel in the position to demand such a 
fundamental change.

For the time being, it seems I have three options:

1) not supplying the sort() function yet (it is not yet in the release, 
but only in my internal devel version)
2) including a dependency to BiocGenerics
3) leaving the problem open, mentioning in the documentation that users 
who want to use apcluster in conjunction with Bioconductor should load 
BiocGenerics first

As far as I got it, there seems to be no other clean way to get rid of 
the problem, right?

Best regards,
Ulrich
On 03/26/2014 02:44 PM, Michael Lawrence wrote: