How to parse date column in pandas
If you have a pandas column containing a date string
df
which is listed as object
:
df["date"]
parse it like this:
df["date"] = pd.to_datetime(df["date"])
After which it will be listed as datetime64[ns]
:
df["date"]