From therneau at mayo.edu  Wed Mar 10 15:30:07 2010
From: therneau at mayo.edu (Terry Therneau)
Date: Wed, 10 Mar 2010 08:30:07 -0600
Subject: [Rd] Defining a method in two packages
In-Reply-To: <40e66e0b1003100536g19fbec98q72f62455a23dc29b@mail.gmail.com>
References: <1267807677.9076.21.camel@punchbuggy>
	<4B92A2C9.1020803@statistik.tu-dortmund.de>
	<alpine.LFD.2.00.1003061952170.14938@gannet.stats.ox.ac.uk>
	<1268064992.26491.31.camel@punchbuggy>
	<4B966702.3090800@statistik.tu-dortmund.de>
	<4B970986.8000603@gmail.com>
	<40e66e0b1003100536g19fbec98q72f62455a23dc29b@mail.gmail.com>
Message-ID: <1268231407.18624.12.camel@punchbuggy>

Doug wrote:
> I think a simpler solution, which I have implemented in lme4 but not
> yet released is to have

> importFrom(nlme, ranef, fixef)

> in the NAMESPACE file of packages that implement methods for those
> generics (and, of course, add nlme to the Imports: specification in
> the DESCRIPTION file).  As nlme is a required package I don't think
> this is too much of a burden.

  I'll do the same change in coxme.  

We can save Kevin Coombe's solution of a separate package of "method
stubs" (which I find very similar in spirit to a shared .h file in C)
for the day that ranef/fixef gets wildly popular.  An importMethods
directive for the namespace is an intriguing long term idea for the core
team to ponder. 

Again, thanks fo all the input.  This discussion has been very
illuminating for me.

Terry T.



[Rd] Defining a method in two packages
Terry Therneau