Skip to content
φ Preprocessing scripts to create reproducible partitions of the nuMoM2b data set. Part of the Indiana University Precision Health Initiative.
Branch: master
Clone or download
hayesall 📝 Updating README.md
Add badges for docs/build/coverage
Add documentation link
Fix example imports now that submodules are imported by default
Latest commit ff85d0e May 13, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
documentation
numom2b_preprocessing
.coveragerc
.gitignore
.travis.yml
LICENSE
README.md
phi_config.json
setup.py

README.md

nuMoM2b Preprocessing — Precision Health Initiative (φ)

A module for creating reproducible partitions of the nuMoM2b data set based on configuration files.

Documentation Status Build Status codecov

Getting Started

Data should not be stored here.

Familiarity with Python, UNIX systems, and Git would be helpful.

Getting Organized

The running assumption is that Data/ contains the .csv files representing the data set, and this nuMoM2b_preprocessing/ repository contains the code and documentation.

Each might be stored as follows (though this may be tweaked through config files):

Precision-Health-Initiative/
├── Data/
│   ├── pregnancy_outcomes.csv
│   ├── Screening.csv
│   └── Visit1.csv
└── nuMoM2b_preprocessing/
    └── README.md

Getting Running

Clone the repository from GitHub:

git clone git@github.com:hayesall/nuMoM2b_preprocessing.git

If you're using Anaconda, this would be a good time to create an environment:

conda create -n PHI python=3.7

... and install dependencies.

pip install -r phi/requirements.txt

Using nuMoM2b_preprocessing

  • As a Package

    Installing using the setup script adds a numom2b_preprocessing package.

    python setup.py install

    ... which can then be imported

    import numom2b_preprocessing
    
    _params = numom2b_preprocessing.parameters(config="phi_config.json")
    numom2b_preprocessing.run(_params)
  • As a Commandline (CLI) Tool

    Installing using setup.py adds an entry point to your default bin/ directory.

    python setup.py install

    This adds a numom2b_preprocessing tool which can be invoked as follows:

    numom2b_preprocessing --help
  • As a Submodule

    nuMoM2b_preprocessing acts as the first step in building classification pipelines. To incorporate it in later learning steps, it may be useful to have access to the methods as a submodule. For general documentation on using submodules, refer to the Git Manual.

    git submodule add git@github.com:hayesall/nuMoM2b_preprocessing.git

    The modules in the package can then be accessed as normal.

    import nuMoM2b_preprocessing.numom2b_preprocessing
    
    _params = numom2b_preprocessing.parameters(config="phi_config.json")
    numom2b_preprocessing.run(_params)

nuMoM2b_preprocessing Documentation

Documentation is not currently hosted at https://doc.numom2b.org/en/latest/, but local copies may be built using Sphinx.

A separate requirements file is in the documentation/ directory.

pip install -r documentation/requirements.txt

A make.bat and Makefile are included:

cd documentation
make html

If the build is successful, a copy will reside in a new build/html/ directory.

open build/html/index.html          # (macOS)
xdg-open build/html/index.html      # (Linux — "should" open with default browser)
You can’t perform that action at this time.