I want to create a DatetimeIndex representing months but the number of days between successive months differs in a periodic manner.
I want it so that every third index the date increases by 5 weeks (35 days) and for all others only 4 weeks (28 days).
As an example I want an output to be like the following:
DatetimeIndex(
['2004-08-01', # start
'2004-08-29', # 28 days added
'2004-10-03', # 35 days added
'2004-10-31', # 28 days added
'2004-11-28', # 28 days added
'2005-01-02', # 35 days added
'2005-01-30', # 28 days added
'2005-02-27', # 28 days added
'2005-04-03', # 35 days added
'2005-05-01', # 28 days added
'2005-05-29']) # 28 days added
Is something like this possible and if so how can I use pandas to achieve it?