You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
to_datetime is not converting input consistently between a pandas series or a python list of either strings or datetime objects. for example:
import pandas as pd
s = pd.Series(['102214','102314'])
df = pd.Series({'dates':['102214','102314']})
lst = ['102214','102314']
pd.to_datetime(s,format='%m%d%y') and pd.to_datetime(df['dates'],format='%m%d%y') return a numpy.datetime64 ndarray, while pd.to_datetime(lst,format='%m%d%y') returns a pandas.DateTimeIndex object. Is this behavior an expected result in 0.15.0?
The text was updated successfully, but these errors were encountered:
The actual values will be the same, but the object type of the output that holds those values depends on the input type: by default it created a DatetimeIndex (eg for lists, arrays, etc as input), only when passed a Series, the output will also be a Series.
to_datetime is not converting input consistently between a pandas series or a python list of either strings or datetime objects. for example:
import pandas as pd
s = pd.Series(['102214','102314'])
df = pd.Series({'dates':['102214','102314']})
lst = ['102214','102314']
pd.to_datetime(s,format='%m%d%y') and pd.to_datetime(df['dates'],format='%m%d%y') return a numpy.datetime64 ndarray, while pd.to_datetime(lst,format='%m%d%y') returns a pandas.DateTimeIndex object. Is this behavior an expected result in 0.15.0?
The text was updated successfully, but these errors were encountered: