[Numpy-discussion] code review for datetime arange

Pierre GM pgmdevlist@gmail....
Fri Jun 10 19:02:21 CDT 2011


On Jun 11, 2011, at 12:57 AM, Mark Wiebe wrote:

> The other issue is how do you define the np.arange step argument since that can be in different scales such as month, years, seconds? Can a user specific days and get half-days (like 1.5 days) or must these be 'integer' days?
> 
> The datetime and timedelta are purely integers, so half-days are only possible by going to hours. I think this is good for datetime, but for timedelta it would be nicer to have a general physical quantities/units system in NumPy, so timedelta would be a regular integer or float with time as its metadata instead of having a timedelta type. That's a whole lot more work though, and doesn't seem like a short term thing...

Better to leave it to a higher level specific package, I'd say (like more specific stats algorithms are in scipy or some scikits).


More information about the NumPy-Discussion mailing list