Installationο
PIP / PyPIο
The easiest way to install PyHPO is via pip
pip install pyhpo
This will install a base version of PyHPO that offers most functionality.
Note
Some features of PyHPO require pandas
and scipy
. The standard installation via pip will not include pandas or scipy and PyHPO will work just fine. (You will get a warning on the initial import though).
Without installing pandas
, you wonβt be able to export the Ontology as a Dataframe
, everything else will work fine.
Without installing scipy
, you wonβt be able to use the stats
module, especially the enrichment calculations.
If you want to do enrichment analysis, you must also install scipy
.
pip install 'pyhpo[scipy]'
If you want to work with PyHPO using pandas
dataframes, you can install the pandas
dependency
pip install 'pyhpo[pandas]'
Or simply install both together:
# Include all dependencies
pip install 'pyhpo[all]'
From sourceο
You can also install PyHPO from source by cloning the git repository:
git clone https://github.com/Centogene/pyhpo.git
I recommend to use a virtual environment to use PyHPO:
cd pyhpo
virtualenv venv
source ./venv/bin/activate
Install dependencies:
pip install -r requirements.txt
Development / Contributingο
If you want to contribute to PyHPO development, first install from source (see above), then install all dev dependencies:
pip install -r requirements_dev.txt
Make sure to install mypy
and linter, such as flake8
or ruff
.