Trying to define a set of rules using pandas.tseries.holidays class but can't figure out how to just create a rule based on another rule. I have the below rule but then want to just create another rule that offsets original rule by one business day:
Thanksgiving:
Holiday("Thanksgiving Day", month=11, day=1, offset=pd.DateOffset(weekday=TH(4))),
Black Friday:
Holiday("Thanksgiving Day", month=11, day=1,
offset=pd.DateOffset(weekday=TH(4))) + pd.DateOffset(1),
Similarly trying to create rule for Cyber Monday which would just be the Monday following Thanksgiving. Tried the below but this returns 11-2
Holiday("Thanksgiving Day", month=11, day=1,
offset=pd.DateOffset(weekday=TH(4)), observance=next_monday)
But above won't work returning
TypeError: unsupported type for add operation