From: Norbert N. <Nor...@gm...> - 2005-01-24 15:57:36
|
Am Montag, 24. Januar 2005 16:09 schrieb John Hunter: > >>>>> "Norbert" == Norbert Nemec <Nor...@gm...> writes: > > Norbert> What about pulling all the plotting routines into a > Norbert> separate file that can be included by anyone who just > Norbert> wants the comfortable plotting commands without all the > Norbert> other namespace cluttering. pylab itself would then only > Norbert> contain lots of imports and all the namespace mangling. > > I think this is a good idea, especially since is a natural way to do > it with the existing organization that shouldn't break much code. We > already have the two modules in place: matplotlib.pylab and pylab. > The former would just export the plotting symbols defined therein and > the latter would be the namespace aggregator. Don't know, whether it is a good idea to make a distinction between pylab and matplotlib.pylab - It would be clearer to create a new module (maybe matplotlib.plotting, matplotlib.pyplot or whatever) and move all routines from pylab to that new module. That would make clear: the term 'pylab' stands for the idea to create an environment that is as similar as possible to matlab. For the question what the new module should contain: only a small, clear-cut set of routines. A regular module should only export what it defines itself. Re-exporting blurs the modularity of the library and makes it harder to understand. Ciao, Norbert -- _________________________________________Norbert Nemec Bernhardstr. 2 ... D-93053 Regensburg Tel: 0941 - 2009638 ... Mobil: 0179 - 7475199 eMail: <No...@Ne...> |