How to standardise different date formats in pandas?
Try removing the format parameter and setting infer_datetime_format=Truein the arguments you pass to pd.to_datetime
I have a dataset in csv format which contains dates in a column. I have imported this dataset into python pandas, and this date column is shown as an object. I need to convert this column to date time but i have a problem. This date column has date format in two formats
1. 11/7/2013  11:51
2. 13-07-2013 08:33:16
I need to convert one format to another one in order to have a standard date format in my python to do analysis. How can i do this?
There are many rows of date in both these formats, so when i try to convert second format to first format using the below code

print(df['date'].apply(lambda x: pd.to_datetime(x, format='%d/%m/%Y
  %H:%M')))

i get the below error

ValueError: time data '13-07-2013 08:33:16' does not match format
  '%d/%m/%Y %H:%M' (match)

so what would be the best method to standardise this column in one format?