Skip to main content

Parser for mwtab files from the Metabolomics Workbench

Project description

License information Current library version Supported Python versions CodeCov Citation link GitHub project

https://raw.githubusercontent.com/MoseleyBioinformaticsLab/mwtab/master/docs/_static/images/mwtab_logo.png

The mwtab package is a Python library that facilitates reading and writing files in mwTab format used by the Metabolomics Workbench for archival of Mass Spectrometry (MS) and Nuclear Magnetic Resonance (NMR) experimental data.

The mwtab package provides facilities to convert mwTab formatted files into their equivalent JSON ized representation and vice versa. JSON stands for JavaScript Object Notation, an open-standard format that uses human-readable text to transmit data objects consisting of attribute-value pairs.

The mwtab package can be used in several ways:

  • As a library for accessing and manipulating data stored in mwTab format files.

  • As a command-line tool to convert between mwTab format and its equivalent JSON representation.

Citation

When using mwtab package in published work, please cite the following papers:

  • Powell, Christian D., and Hunter NB Moseley. “The mwtab Python Library for RESTful Access and Enhanced Quality Control, Deposition, and Curation of the Metabolomics Workbench Data Repository.” Metabolites 11.3 (2021): 163. doi: 10.3390/metabo11030163.

  • Smelter, Andrey and Hunter NB Moseley. “A Python library for FAIRer access and deposition to the Metabolomics Workbench Data Repository.” Metabolomics 2018, 14(5): 64. doi: 10.1007/s11306-018-1356-6.

Installation

Install on Linux, Mac OS X

python3 -m pip install mwtab

Install on Windows

py -3 -m pip install mwtab

Upgrade on Linux, Mac OS X

python3 -m pip install mwtab --upgrade

Upgrade on Windows

py -3 -m pip install mwtab --upgrade

Quickstart

>>> import mwtab
>>>
>>> # Here we use ANALYSIS_ID of file to fetch data from URL
>>> for mwfile in mwtab.read_files("1", "2"):
...      print("STUDY_ID:", mwfile.study_id)
...      print("ANALYSIS_ID:", mwfile.analysis_id)
...      print("SOURCE:", mwfile.source)
...      print("Blocks:", list(mwfile.keys()))
>>>
https://raw.githubusercontent.com/MoseleyBioinformaticsLab/mwtab/master/docs/_static/images/mwtab_demo.gif

License

This package is distributed under the BSD license.

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

mwtab-2.1.0.tar.gz (2.9 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mwtab-2.1.0-py3-none-any.whl (77.1 kB view details)

Uploaded Python 3

File details

Details for the file mwtab-2.1.0.tar.gz.

File metadata

  • Download URL: mwtab-2.1.0.tar.gz
  • Upload date:
  • Size: 2.9 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for mwtab-2.1.0.tar.gz
Algorithm Hash digest
SHA256 1158f7280a676dfb0187770638dd1a91ecb1e1a4c78ebde90bb91d9f0d44b872
MD5 794e2703c6bc67b60032f955567b71d0
BLAKE2b-256 6fd9e8f77c8ff850304f73a671ace9d31784a3199599586e708380dd8aacca21

See more details on using hashes here.

File details

Details for the file mwtab-2.1.0-py3-none-any.whl.

File metadata

  • Download URL: mwtab-2.1.0-py3-none-any.whl
  • Upload date:
  • Size: 77.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for mwtab-2.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 9e0d0e4ee348c93cd8c462b3b184ef686e39fc7da7768d38a7a128c19ee5c138
MD5 af2728a314a33c2ca73a153ef3fb386c
BLAKE2b-256 fce45d5d9a7640918fb080cd9de384ae8adae773b72ee7943ec05191097d4af6

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page