0

My expectation:

'2019-02-01' + 1 month -> '2019-03-01'

My try code:

(pd.Timedelta(1, unit = 'M') + pd.to_datetime('2019-01-01'))

However it ends up with this result:

Timestamp('2019-03-03 10:29:06')

I want it to be exactly the first day of the month

Chau Loi
  • 1,106
  • 1
  • 14
  • 36

0 Answers0