Skip to main content

Functions to handle business days calculations

Project description

Downloads Latest Version Supported Python versions Development Status

python-bizdays

In several countries and markets, the accountability of the price of a financial instrument, mainly bonds and derivatives, involves the use of different rules to compute the way the days go by. In some countries, like in Brazil, several financial instrument only pay interest for business days along their life cycle. Therefore, having a way to compute the number of business days between 2 dates is quite useful to price the financial instruments properly. It is necessary the holidays which occur between the 2 dates, to compute the business days and they are intrinsically related to counties and local markets. In Brazil, ANBIMA prepares a file with a list of holidays up to the year of 2078 which is largely used by market practioners for pricing financial instruments.

Several financial libraries compute the holidays, giving no option to users set it by their own. Furtherly, the financial calendar is usually a small feature of a huge library, as quantlib, for example, and some users, including myself, don't want to put a hand in such a huge library only to use the financial calendar.

bizdays is a pure Python module relying on its simplicity and the power of Python's batteries. bizdays computes business days between two dates and other collateral effects, like adjust a given date for the next or previous business day, check whether a date is a business day, creates generators of business days sequences, and so forth. bizdays is a module without further dependencies, what makes it appropriated for small implementations.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

bizdays-1.0.0.tar.gz (8.9 kB view hashes)

Uploaded Source

Built Distribution

bizdays-1.0.0-py3-none-any.whl (3.0 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page