Skip to content

The nPYc-Toolbox defines objects for representing, and implements functions to manipulate and display, metabolic profiling datasets.

Notifications You must be signed in to change notification settings

jordan129/nPYc-Toolbox

 
 

Repository files navigation

nPYc Toolbox

Build Status Documentation Status codecov Python36 PyPI

A Python implementation of the NPC toolchain for the import, quality-control, and preprocessing of metabolic profiling datasets.

Imports:

  • Peak-picked LC-MS data (XCMS, Progenesis QI, & Metaboscape)
  • Raw NMR spectra (Bruker format)
  • Targeted datasets (TargetLynx, Bruker BI-LISA & BI-Quant-Ur)

Provides:

  • Batch & drift correction for LC-MS datasets
  • Feature filtering by RSD and linearity of response
  • Calculation of spectral line-width in NMR
  • PCA of datasets
  • Visualisation of datasets

Exports:

Installation

To install via pip, run:

pip install nPYc

To install from a local copy of the source, simply navigate to the main package folder and run:

python setup.py install

Alternatively, using pip and a local copy of the source:

pip install /nPYC-toolboxDirectory/

Installation with pip allows the usage of the uninstall command

pip uninstall nPYc

Documentation

Documentation is hosted on Read the Docs.

Documentation is generated via Sphinx Autodoc, documentation markup is in reStructuredText.

To build the documentation locally, cd into the docs directory and run:

make html

To clear the current documentation in order to rebuild after making changes, run:

make clean

Development

Source management is git-flow-like - no development in the master branch! When making a change, create a fork based on develop, and issue a pull request when ready.

When merging into the develop branch, all new code must include unit-tests, all tests should pass, and overall code-coverage for the toolbox should not drop.

Releases

When merging from develop (or hotfix branches) into release, ensure:

  • All references to the debugger are removed
  • All paths are relative and platform agnostic
  • All tests pass

Testing

Unit testing is managed via the unittest framework. Test coverage can be found on codecov.io.

To run all tests, cd into the Tests directory and run:

python -m unittest discover -v

Individual test modules can be run with:

python -m `test_filename` -v

Standard measures and codings

When stored internally, and unless explicitly overriden, variables should conform to the units laid out in the Nomenclature of the documentation.

About

The nPYc-Toolbox defines objects for representing, and implements functions to manipulate and display, metabolic profiling datasets.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Python 93.7%
  • Jupyter Notebook 3.2%
  • HTML 2.7%
  • CSS 0.4%