Skip to content
Back to formatted view

Raw Message

Message-ID: <Pine.LNX.4.61.0508261643370.11188@gannet.stats>
Date: 2005-08-26T15:45:57Z
From: Brian Ripley
Subject: Functions with the same name: best practices
In-Reply-To: <f8e6ff05050826083030aee9b8@mail.gmail.com>

On Fri, 26 Aug 2005, hadley wickham wrote:

> Thanks to all of you for your advice. I will read up on namespaces and
> start using them to "protect" my internal function from name clashes
> with other packages, and endeavour to my public functions unique
> names.
>
> I know other languages (eg. python) separate loading a package and
> including it in the default namespace, do you think R will ever move
> to such a system?

I don't follow the terminology here, but in R you can load a namespace 
without making the exports visible, which sounds like what you are asking. 
In R `loading a package' means making its objects visible from the 
top-level scope.

-- 
Brian D. Ripley,                  ripley at stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595