Skip to main content

A package for preprocessing mzML files for ZooMS analysis

Project description

preprocessmzML

A simple python package for preprocessing mzML spectra using various filters and normalization techniques derived from the fantastic pyopenms package. This package supports baseline correction, smoothing, centroiding, and normalization of spectra from MALDI-TOF mass spectrometers.

Features

  • Baseline Correction: Remove baseline using MorphologicalFilter
  • Smoothing: Smooth the spectrum using Savitzky-Golay filter
  • Centroiding: Pick peaks with PeakPickerHiRes
  • Normalization: Normalize spectra with different methods (TIC, To the most intense peak)

Installation

Prerequisites

  • Python 3.6 or higher
  • pip (Python package installer)

macOS or Linux systems

  1. Create and activate a virtual environment:
python3 -m venv preprocess_mzml
source venv/bin/activate
  1. Install the package:
pip install preprocessmzML

Windows

  1. Create and activate a virtual environment:
python -m venv venv
venv\Scripts\activate
  1. Install the package:
pip install preprocessmzML

To install the package, use the following command:

pip install preprocessmzML

Usage

After installing the package, you can preprocess your mzML files from the command line (in a virtual environment as described above). I highly recommend running this workflow within a virtual environment to tackle version conflicts of modules used in this package.

Command-Line Interface (CLI)

preprocess_mzml --data_dir /path/to/mzML/files --output_base_dir /path/to/output/directory

Troubleshooting

If you encounter issues, please check the following:

  • Ensure that the mzML files are correctly formatted and accessible.
  • Verify that the output directory is writable.
  • Check the parameter combinations for any invalid values.

Contributing

Contributions are always welcome. Feel free to submit a pull request or open an issue on Github.

License

This project is licensed under the MIT License - see the LICENSE file for details.

Author

Bharath Nair bharath@palaeome.org; bn317@cam.ac.uk

Acknowledgements

  • pyopenms
  • pandas
  • numpy
  • matplotlib

This README.md includes:

  • A brief introduction to the package and its features.
  • Installation instructions.
  • Usage examples.
  • Detailed function documentation.
  • Contribution guidelines.
  • License information.
  • Author information.
  • Acknowledgements for dependencies.

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

preprocessmzML-0.1.0.tar.gz (5.7 kB view details)

Uploaded Source

Built Distribution

preprocessmzML-0.1.0-py3-none-any.whl (7.1 kB view details)

Uploaded Python 3

File details

Details for the file preprocessmzML-0.1.0.tar.gz.

File metadata

  • Download URL: preprocessmzML-0.1.0.tar.gz
  • Upload date:
  • Size: 5.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.13

File hashes

Hashes for preprocessmzML-0.1.0.tar.gz
Algorithm Hash digest
SHA256 bc49a6b9ee26b57faa7bee1a38f26596d8d66d877e43d0114f1b252ce7f9c1b5
MD5 ffd45345fef6a0ac61f4ebfa29b60d8e
BLAKE2b-256 2b0b0ed2f386110edb693eb46eed63fc0b51f5cfb566af3395f6d0b16ef358ac

See more details on using hashes here.

File details

Details for the file preprocessmzML-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for preprocessmzML-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 4c2edaaed89c699281eed65026480c223568cd6ff47651a8ffa935ce0da86e0a
MD5 8658c5e663349b78c20a9937563d874f
BLAKE2b-256 2d920a0e16f3381fcf5633fbd6744977f4e4657d268f122a963f20c531094a44

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