Skip to main content

Brazilian financial market calendar utilities for business days, holidays, and date operations.

Project description

br-market-calendar

Brazilian financial market calendar utilities for Python.

br-market-calendar provides a simple, explicit, and well-tested API for working with Brazilian financial market dates, business days, holidays, day count conventions, and financial schedules.

The project is designed for both Brazilian users and international users who need reliable date utilities for the Brazilian market.

Features

  • Brazilian financial business day calendar
  • ANBIMA-compatible holiday readers
  • CSV, Excel, and URL holiday loading
  • Business day adjustment conventions
  • Day count conventions
  • Financial schedule generation
  • Date parsing and formatting helpers
  • Calendar day and weekday ranges
  • Business day ranges and business days per month
  • First/last day of month and weekday name helpers
  • Typed, tested, and lightweight core

Installation

pip install br-market-calendar

Quick examples

from br_market_calendar import BrazilFinancialCalendar, date_range, days_between

cal = BrazilFinancialCalendar.from_holidays(["2026-01-01"])

# Calendar days
date_range("01/01/2026", "05/01/2026")

# Number of calendar days
days_between("2026-01-01", "2026-01-05", inclusive=True)

# Business days, excluding weekends and holidays
cal.business_days("2026-01-01", "2026-01-05")

# Number of business days
cal.business_days_between("2026-01-01", "2026-01-05", inclusive=True)

# Business days grouped by month
cal.business_days_per_month("2026-01-01", "2026-02-03")

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

br_market_calendar-0.2.2.tar.gz (43.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

br_market_calendar-0.2.2-py3-none-any.whl (13.9 kB view details)

Uploaded Python 3

File details

Details for the file br_market_calendar-0.2.2.tar.gz.

File metadata

  • Download URL: br_market_calendar-0.2.2.tar.gz
  • Upload date:
  • Size: 43.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.9

File hashes

Hashes for br_market_calendar-0.2.2.tar.gz
Algorithm Hash digest
SHA256 7a2bcff08a34f8e39b32895eb6cbc748db4e0039efadc7d8adc2096a60dc67b2
MD5 3bea9ddf62311d8f5ea0f06dcd894257
BLAKE2b-256 fff4a91e337eb7bd26d77bb0b45920f4bf1add8614f5d91b731062adbb10aab8

See more details on using hashes here.

File details

Details for the file br_market_calendar-0.2.2-py3-none-any.whl.

File metadata

File hashes

Hashes for br_market_calendar-0.2.2-py3-none-any.whl
Algorithm Hash digest
SHA256 c2ff6fc1aa781e49c336176d250fdc0f2f96811d0efd2cfd5f231c4e9b6cedc1
MD5 c8072a3ffb18e2bce6d67cb9790d67b6
BLAKE2b-256 7213d603690d5ad9c00da611f8670cd3d535b9fdcc53afa99cba11a21128b41d

See more details on using hashes here.

Supported by

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