Skip to main content
License information Current library version Supported Python versions Documentation status Travis CI status Code coverage information Citation link

https://raw.githubusercontent.com/MoseleyBioinformaticsLab/nmrstarlib/master/docs/_static/images/nmrstarlib_logo.png

The nmrstarlib package is a Python library that facilitates reading and writing NMR-STAR formatted files used by the Biological Magnetic Resonance Data Bank (BMRB) for archival of Nuclear Magnetic Resonance (NMR) data and CIF formatted files used by Protein Data Bank (PDB).

The nmrstarlib package provides facilities to convert NMR-STAR and CIF formatted files into their equivalent JSONized 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 nmrstarlib package also provides facilities to create simulated peak lists for different types of standard solution and solid-state NMR experiments from chemical shifts and assignment information deposited in NMR-STAR files.

In addition, the nmrstarlib package provides methods to visualize chemical shift data.

The nmrstarlib package can be used in several ways:

  • As a library for accessing and manipulating data stored in NMR-STAR and CIF formatted files.

  • As a command-line tool to convert between NMR-STAR/CIF format and its equivalent JSONized NMR-STAR/CIF format, to create a large number of simulated peak lists, and also to visualize chemical shift data from NMR-STAR formatted files.

Citation

When using nmrstarlib in published work, please cite the following paper:

  • Smelter, Andrey, Morgan Astra, and Hunter NB Moseley. “A fast and efficient python library for interfacing with the Biological Magnetic Resonance Data Bank.” BMC Bioinformatics 18.1 (2017): 175. doi: 10.1186/s12859-017-1580-5.

Installation

The nmrstarlib package runs under Python 2.7 and Python 3.4+. Use pip to install. Starting with Python 3.4, pip is included by default.

Install on Linux, Mac OS X

python3 -m pip install nmrstarlib

Install on Windows

py -3 -m pip install nmrstarlib

Quickstart

Import nmrstarlib library and create generator function that will yield StarFile instance(s):

>>> import nmrstarlib
>>>
>>> # "path": path_to_file / path_to_dir / path_to_archive / bmrb_id / pdb_id / file_url
>>> for file in nmrstarlib.read_files("path"):
...     print(file.id)      # print BMRB/PDB id of a file
...     print(file.source)  # print source of a file
...     print(file.keys())  # print top-level keys
>>>
https://raw.githubusercontent.com/MoseleyBioinformaticsLab/nmrstarlib/master/docs/_static/images/nmrstarlib_demo.gif

License

This package is distributed under the MIT license.

Release files for nmrstarlib 2.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for nmrstarlib 2.1.1
File Size Uploaded
nmrstarlib-2.1.1.tar.gz 2.4 MB Details

Release files / nmrstarlib-2.1.1.tar.gz

Download URL nmrstarlib-2.1.1.tar.gz
Size 2.4 MB
Tags Source
SHA-256 checksum
How to use checksums
bd6119a21a9184ea6f06c04ac7782baa982926a0bbf0c24760e154b690905a39
BLAKE2b-256 checksum
How to use checksums
e15373f62bfaa068c0a55e3593efc384899f93017d9ddfaf44c25d53392289ad
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

This release

2.1.1 This release

1 release file

2.1.0

1 release file

2.0.6

1 release file

2.0.5

1 release file

2.0.4

1 release file

2.0.3

1 release file

2.0.2

1 release file

2.0.1

1 release file

2.0.0

1 release file

1.1.0

1 release file

1.0.4

1 release file

1.0.3

1 release file

1.0.2

1 release file

1.0.1

1 release file

1.0.0

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page