ModifiedHolidayCalendar#
-
class sigtech.framework.infra.calendar.calendar.ModifiedHolidayCalendar
Baseclasses:
HolidayCalendar
Class representing a modified HolidayCalendar object, consisting of the original calendar plus some extra holidays added and/or removed
Keyword arguments:
weekend
- List of weekend days.type
- Indicate if the calendar is maintained by external provider or internal.description
: Calendar description.base_calendar_name
- Underlying calendar that is being modified. (If skipped, empty calendar is used).add_holidays
- List of additional holidays (can be empty, or contain existing holidays).remove_holidays
- List of holidays to be removed (can be empty, or contain days which are not holidays).
Example of object creation:
from sigtech.framework.infra.calendar.calendar import ModifiedHolidayCalendar calendar = ModifiedHolidayCalendar( weekend=['saturday', 'sunday'], description='Test Calendar', base_calendar_name='FEDFUND CALENDAR', name='NEW_FEDFUND CALENDAR', add_holidays=[dtm.date(1966,1,1)], remove_holidays=[dtm.date(1966,2,2)] # this date will be ignored, as it is not a holiday )
-
add_holidays: Optional[list[datetime.date]]
-
base_calendar_name: Optional[str]
-
remove_holidays: Optional[list[datetime.date]]