2011/7/25 Stéfan van der Walt
On Mon, Jul 25, 2011 at 1:02 PM, Mark Wiebe
wrote: Probably should have! Either way, it's something to consider: if we introduce those functions now, people will start to use them where they are (np.xyz), introducing another change in usage comes 2.0 (or 3.0 or whichever).
Absolutely, do you have any suggestions about organizing the datetime functionality? It's as good a place as any to try applying a good namespace convention.
The first thought that comes to mind is simply to keep them in a submodule, so that users can do something like:
from numpy.datetime import some_date_func
That convention should be very easy to support across the restructuring. The important thing then is to document clearly that these functions are available.
Can't use numpy.datetime, since that conflicts with Python's datetime library, especially in pylab. Can't use numpy.datetime64, since that's already the name of the scalar type. I don't like numpy.dt, that name belongs to a delta t variable in Python. I'm not sure what a good name for the namespace is, actually. -Mark
Regards Stéfan _______________________________________________ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion