Skip to main content

Python wrapper for the OHDSI R packages

Project description

python-ohdsi

PyPI Circe PyPI DatabaseConnector PyPI FeatureExtraction PyPI SQLRender

Python wrappers for (some) OHDSI tools. This project has been initiated for supporting OMOP data sources in vantage6.

Make sure you have a working R environment with the OHDSI packages installed.

Installation

Python binding

Interact with the OMOP database using a python interface.

  • Install Java JDK.
  • Install R: sudo apt-get install r-base (set R_HOME)
  • Install R packages
pip install python-ohdsi

API service

Spin up a small webserver next to the OMOP database to allow HTTP requests to the OMOP database. You can use the prebuild image from dockerhub:

docker pull ...
docker run ...

Or you can build the image yourself:

docker build -t ohdsi-api .
docker run -p 5000:5000 ohdsi-api

Or you can run the API service directly from the source code:

pip install -r requirements.txt
python api.py

Building documentation

cd docs
export IGNORE_R_IMPORTS=True
make html
cd docs
Set-Item -Path Env:IGNORE_R_IMPORTS -Value True
make html

or you can use make livehtml to automatically rebuild the documentation when a file is changed.

You can set the IGNORE_R_IMPORTS environment variable to ignore the R imports in the documentation. This is useful when you don't have the R packages installed but want to build the documentation anyway.

User Documentation

The user documentation can be found at readthedocs.

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

ohdsi-database-connector-0.3.0.tar.gz (936.4 kB view details)

Uploaded Source

Built Distribution

ohdsi_database_connector-0.3.0-py3-none-any.whl (935.0 kB view details)

Uploaded Python 3

File details

Details for the file ohdsi-database-connector-0.3.0.tar.gz.

File metadata

File hashes

Hashes for ohdsi-database-connector-0.3.0.tar.gz
Algorithm Hash digest
SHA256 ddc59d3a266c835998a0d7bfb2e25dbc22e704ac4896de73732b8ee2d8409378
MD5 61e5ea603449128d63e66b370ce7fb52
BLAKE2b-256 8a3486ee3fdb028362828f1a12b49f978310f8d15b9a65c2b82982e25f124b42

See more details on using hashes here.

File details

Details for the file ohdsi_database_connector-0.3.0-py3-none-any.whl.

File metadata

File hashes

Hashes for ohdsi_database_connector-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 4628dfd8d7865eee6578ab58bbce07f1de4648f95010b7b3975e14b3ed9db12c
MD5 fdc34a856a98f4fb1df3122efc521f65
BLAKE2b-256 bb5a07aaaa4ea3a6c400d43b83c24ab1ae8bf55378cac6a3f7c123fc7bcc6e31

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