Skip to main content

Calculate birthrate and mortality from WPP data

Project description

pyvd

pyvd calculates birth and mortality rates from UN WPP projections for a single country.

Basic usage

  1. Install
pip install pyvd
  1. In a python terminal or script, calculate demography (e.g., birth rates by year)
pop_input = make_pop_dat('IND')
year_vec = pop_input[0, :] - pyvd.constants.BASE_YEAR
year_init = pyvd.constants.BASE_YEAR - pyvd.constants.BASE_YEAR
pop_mat = pop_input[1:, :] + 0.1
pop_init = [np.interp(year_init, year_vec, pop_mat[idx, :])
            for idx in range(pop_mat.shape[0])]
vd_tup = demog_vd_calc(year_vec, year_init, pop_mat, pop_init)

More about the data

You can learn about the data here. We combine both the retrospective (past) and projection (future) estimate, using the medium variant for the projects.

Coming soon

  • Subnational estimates

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

pyvd-0.4.4.tar.gz (2.9 MB view details)

Uploaded Source

Built Distribution

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

pyvd-0.4.4-py3-none-any.whl (2.9 MB view details)

Uploaded Python 3

File details

Details for the file pyvd-0.4.4.tar.gz.

File metadata

  • Download URL: pyvd-0.4.4.tar.gz
  • Upload date:
  • Size: 2.9 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.0.1 CPython/3.12.8

File hashes

Hashes for pyvd-0.4.4.tar.gz
Algorithm Hash digest
SHA256 5f68a8e3a7e5ae6f6e371a430248c837b37b64eddcbd2591d6f27275b2975a0e
MD5 49cfa5ed6f25f4ad3ddb66ff9a01f9aa
BLAKE2b-256 5272b17e0570a081f70a6d37bd1aac36ca7a99b7e013f1155fde0044b587faa8

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyvd-0.4.4.tar.gz:

Publisher: publish_pypi.yml on krosenfeld-IDM/pyvd

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pyvd-0.4.4-py3-none-any.whl.

File metadata

  • Download URL: pyvd-0.4.4-py3-none-any.whl
  • Upload date:
  • Size: 2.9 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.0.1 CPython/3.12.8

File hashes

Hashes for pyvd-0.4.4-py3-none-any.whl
Algorithm Hash digest
SHA256 b600b1224d37a390c7c926ff069e22cd692abc64fa86ead3c2319bc272a0d658
MD5 db3eb005810b7bef519ee8eea1752cfd
BLAKE2b-256 519f3cbbc2018c2741ad35ce88e36d31aa3f8ace00a4a417d6a8e28996727e29

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyvd-0.4.4-py3-none-any.whl:

Publisher: publish_pypi.yml on krosenfeld-IDM/pyvd

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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