Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Do you know an awesome Python library for manipulating dates? [closed]

I search an awesome Python library date like Moment.js. Do you know some?

I want especially a library that can do conversions like this: 09/25/2012 00:00 - 09/25/2012 13:00 to 09/25/2012 00:00 - 13:00.

like image 719
tsil Avatar asked Sep 19 '12 10:09

tsil


People also ask

Which Python library is commonly used for data wrangling and manipulation?

Pandas. Pandas is one of the libraries powered by NumPy. It's the #1 most widely used data analysis and manipulation library for Python, and it's not hard to see why.

Which Python libraries are most efficient for data processing?

Pandas (Python data analysis) is a must in the data science life cycle. It is the most popular and widely used Python library for data science, along with NumPy in matplotlib.

Is datetime a library in Python?

Python's built-in datetime library is one of the most common modules to manipulate date and time object data. You can create date and datetime objects, loop through a range of dates, parse and format date strings, and more.


3 Answers

Some Python libraries inspired by Moment.js:

  • arrow
  • delorean
  • moment

Arrow and Delorean seem a bit more mature, although I have not really used any of them extensively.

like image 130
NeilenMarais Avatar answered Sep 20 '22 08:09

NeilenMarais


datetime and it comes with the standard library. And here is Doug Hellman's introduction to the "module of the week".

like image 23
root Avatar answered Sep 22 '22 08:09

root


You can try these 3rd party packages:

  • dateutil
  • mxDatetime : its parser is pretty good. Check whether the license works for you, though.
like image 32
Pierre GM Avatar answered Sep 21 '22 08:09

Pierre GM