[R] Clash between alr3 and AlgDesign. (Was: Re: Second & subsequent calls to function fails. Please help debug.)
Duncan Murdoch
murdoch at stats.uwo.ca
Sun Mar 30 19:25:05 CEST 2008
On 30/03/2008 11:31 AM, Gabor Grothendieck wrote:
> On Sun, Mar 30, 2008 at 9:43 AM, Duncan Murdoch <murdoch at stats.uwo.ca> wrote:
>> In my opinion, all packages should have namespaces, and I'd like to
>> create a default one if the author doesn't. (The default would be:
>> import what is listed in the Depends clause, export everything.) I
>> don't think this will happen for 2.7.0, though package.skeleton might
>> start creating one.
>
> Namespaces are such a pain when you don't really need them though.
I would say there is no such case. Packages all import functions.
Having the imports change because of unrelated code means that there is
no way to write reliable code.
> Its nice just to be able to source a new version of a function and have
> it immediately work with the package. Particularly for packages that
> are changing or for which there is substantial code changes in the
> devel version this is very convenient and namespaces interefere with that.
That sounds like a problem with the way we handle package code, making
it too hard to reload a package that has had small changes made. We
should make it easy to make a small change to a package and reload the
modified version.
> Although its possible to have namespace problems as discussed in this
> thread I have found that it rarely actually happens and certainly not enough
> to impose it.
I suspect it happens more than people realize, and that in some cases
they just get the wrong answers, without any helpful error message to
let them know about it.
Duncan Murdoch
More information about the R-help
mailing list