aquamad96
aquamad96

Reputation: 63

How to convert month-year time string to time?

How can I convert a date string like "Jan-95" to actual date Jan-95 or something similar?

Thank you

Upvotes: 0

Views: 59

Answers (1)

user7753123
user7753123

Reputation:

df['DataFrame Column'] = pd.to_datetime(df['DataFrame Column'], format=specify your format)

format in your case would be:

format='%b-%y'

Upvotes: 3

Related Questions