<div class="gmail_quote"><div>hi all,</div><div><span style="background-color: transparent; "> </span></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div class="im">


> That said, the major problem is that the current organization of the<br>
> major packages is not logical or intuitive.  numpy has arrays,<br>
> algorithms and IO, scipy has algorithms and IO, matplotlib has<br>
> plotting and algorithms and IO, pandas has datastructures, IO,<br>
> algorithms and plotting (albeit all organized around the dataframe).<br>
> And so on.  I think there is room for a namespace package that<br>
> integrates across these and makes it more intuitive.  The proper top<br>
> level namespaces are something like: array (or statstructures more<br>
> generally), algo, plot, io.  In this model, you would pull the<br>
> relevant components from numpy, scipy, mpl, pandas, scikits, ETS, etc<br>
> into the relevant namespaces.<br>
<br>
</div>I would not want to make the new namespace nested - it should be flat<br>
like the current pylab is.  I think the main point here is that we are<br>
competing with Matlab, Mathematica, etc. which all have completely<br>
flat namespaces.  Not that we want to copy everything these packages<br>
do, but for new users, non-technical folks, undergraduates the entire<br>
idea of namespaces is confusing.  This problem (for these users) is<br>
namspaces themselves, not just that the existing ones are confusing.<br></blockquote><div><br></div><div>i don't think what confuses new users is whether the namespace is flat or nested, but where to get the functionality that they are looking for and if in the nested namespace there are multiple implementations of the functionality, which one to use. </div>

<div><br></div><div>even in matlab, which has a flat namespace, users need to do 'lookfor' to search for available functions. and in cases where additional toolboxes are installed which may have the same function filename, it's a nightmare.</div>

<div><br></div><div>so i think the notion of namespace is crucial in the scientific computing world and the import statement is not the biggest block that new users face. most often, it is: 'which function solves my problem?'. for example, <span style="background-color: transparent; ">*once* you know 'plot', 'hist' and 'imshow' are in pyplot, it's really trivial for most users to type:</span></div>

<div><br></div><div>---</div><div>import matplotlib.pyplot as plt</div><div><span style="background-color: transparent; ">or</span></div><div><span style="background-color: transparent; ">from matplotlib.pyplot import plot, hist, imshow</span></div>

<div>---</div><div><br></div><div>i agree with john that having namespaces like:</div><div><br></div><div>stats</div><div>io</div><div>plot</div><div>linalg </div><div><br></div><div>might actually be useful in categorizing and looking for functionality, which i believe was the one of the intents of namespaces in the first place.</div>

<div><br></div><div><div>if the goal is to provide matlab compatibility and assume that function names and their calling structures are identical, then the flat namespace helps. however, beyond some routines, this is impossible to maintain.</div>

</div><div><br></div><div>i think scientific computing in python would do very well if some mechanism like 'lookfor' provided users (especially new users) a good way to find functionality. i don't think the flat namespace solves this problem. </div>

<div><br></div><div>cheers,</div><div><br></div><div>satra</div><div><br></div><div><br></div></div>