Gist 6e70c835e46d4292e11d165fd0f22c77
✓ Published0🌍 Public
JJonasHeylen
Last edited Jan 12, 2017
Created on Jan 12, 2017
This example visualizes the number of business days per month in Belgium for 2017, using a custom holiday calendar to exclude public holidays. It shows how many working days each month contains, revealing monthly variation. The code relies on pandas’ `CustomBusinessDay` offset with a `BelgianHolidayCalendar` subclass of `AbstractHolidayCalendar`, defining holidays like Easter Monday and Ascension via `Easter` and `Day` offsets. Business days are generated with `pd.date_range`, then resampled monthly with `.resample('M').count()` to produce the counts. The visualization’s data originates from the calendar logic, not an external dataset.
AI-generated description