The following piece of code:
import pandas as pd
import numpy as np
data = pd.DataFrame({\'date\': (\'13/02/2012\', \'14/02/2012\')})
data[\'date\'] = data[
Do this instead. Pandas keeps datestimes internally as datetime64[ns]
. Conversions
like this are very buggy (because of issues in various numpy version, 1.6.2 especially). Use
the pandas routines, then operate like thesee are actual datetime objects. What are you trying to do?
In [30]: pandas.to_datetime(data['date'])
Out[30]:
0 2012-02-13 00:00:00
1 2012-02-14 00:00:00
Name: date, dtype: datetime64[ns]