Skip to main content

Matrix population models library with an interface to the COMPADRE / COMADRE databases.

Project description

Matpopmod - Matrix Population Models in Python

Matpopmod is a Python library for the study of matrix population models. It can be used to:

  • compute a wide variety of demographic descriptors;
  • study and plot deterministic and stochastic trajectories;
  • access the COMPADRE/COMADRE databases.

See the project homepage for more information.

Installation

Matpopmod requires Python ≥3.6 with NumPy ≥1.10 and Matplotlib. You can install the latest stable version from PyPI with:

python3 -m pip install matpopmod

Usage

Matpopmod can be used interactively or as a library in Python scripts. See the quickstart guide and the documentation for details.

Development

Contributions are welcome on the Git lab repository.

Installing the development version

You can install the current development version using:

python3 -m pip install https://gitlab.com/bienvenu/matpopmod/-/archive/master/matpopmod-dev.tar.gz

However, if you want to be able to run the tests, build the documentation and contribute, we recommend fetching the source and setting up a development environment with:

git clone https://gitlab.com/bienvenu/matpopmod.git
python3 -m venv env
source env/bin/activate
python3 -m pip install -e matpopmod/

Running tests

python3 -m pip install pytest
pytest matpopmod

Show test coverage:

python3 -m pip install pytest-cov
pytest --cov=matpopmod --cov-report html
python3 -m http.server 8002 # serve

Building the documentation

# HTML documentation in /public
python3 -m pip install sphinx
cd matpopmod
sphinx-build -b html doc/ public
# PDF documentation in /public
python3 -m pip install sphinx
cd matpopmod
sphinx-build -b latex doc/ public
cd public
pdflatex matpopmod.tex

Building the package

The version number is maintained in src/matpopmod/VERSION.

python3 -m build .
# To upload the package on PyPI
python3 -m twine upload dist/*

License

This project is licensed under the GNU Lesser General Public License v3.0 or later.

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

matpopmod-0.1.1.tar.gz (80.1 kB view details)

Uploaded Source

Built Distribution

matpopmod-0.1.1-py3-none-any.whl (84.9 kB view details)

Uploaded Python 3

File details

Details for the file matpopmod-0.1.1.tar.gz.

File metadata

  • Download URL: matpopmod-0.1.1.tar.gz
  • Upload date:
  • Size: 80.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.21.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.7.3

File hashes

Hashes for matpopmod-0.1.1.tar.gz
Algorithm Hash digest
SHA256 e674c1c1586bb1359fbdbf23b12abecd948dfcd40e4c8fae29d46277bd2f1ac8
MD5 e55f701cfd69e265fbb497f40a4cdef4
BLAKE2b-256 d5373d70c19937e372a910b64b024e1ccb03d4fff5f51f71be76a8477d0ffc5a

See more details on using hashes here.

File details

Details for the file matpopmod-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: matpopmod-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 84.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.21.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.7.3

File hashes

Hashes for matpopmod-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 eee2c144ac761dda9e4e65f8c8f8eaeb8db559a2a5f41ef533c5dcdb5c7b60de
MD5 8b6343ccd0424872e7789dd9ccc20738
BLAKE2b-256 5821be99e72355200fa8489151aa1077ef80a52f046bb1eb546330dcd955fabb

See more details on using hashes here.

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