BMRB serves Nuclear Magnetic Resonance(NMR) community by providing high quality curated chemical shift data of various biologically important macro molecules like proteins and nucleic acids and small molecules like ligands , co-factors, small peptides and metabolites. Chemical shift distribution of an atom in an amino acid or nucleic acid helps us to understand its diverse chemical environment. Chemical shift histograms from a database like BMRB will help us to understand the biophysical nature bio-molecules and provides a priory probabilities for resonance assignments.
In [ ]:
from pybmrb import csviz
The default output for any visualization generated using this library is an interactive html file. It also supports the famous Notebook style embaded visualizations. To enable Notebook mode set the NOTEBOOK varibale True.
In [ ]:
csviz.NOTEBOOK = True
Let's call the histogram method
In [ ]:
h = csviz.Histogram()
In [ ]:
help(h.hist)
The function hist may take any one of the parameters residue/atom/atom_list or two parameters residue and atom along with filtering and normalization parameters. The outfilename is used to generate visualizations as a stand alone html file.
BMRB contains chemical shifts of atom in different experimental conditions. In order to get a clean distribution, exoctic values(arising from say para-magnetic substances or different experimental conditions) should be removed. This is done by a filter based on standard deviation of that particularity distribution. For a given distribution, the values lie outside sd_limt x standard deviation will be removed. By default this filter is enabled and the sd_litmit is set to 10
One can also plot probability density instead of count. This can be controlled by the parameter normalized. By default its false, which means it will plot the count/frequency.
Let's see some examples
In [ ]:
h.hist(residue='LYS',atom='C*')
To filter only unambiguously assigned checmical shifts use ambiguity = 1. The ambiguity codes are defined in the NMR-STAR dictionary.
In [ ]:
h.hist(residue='LYS',atom='C*',ambiguity=1)
In [ ]:
h.hist(atom_list=['LYS-CB','CYS-CB','ALA-CA'])
In [ ]:
h.hist(atom_list=['LYS-CB','CYS-CB','ALA-CA'],normalized=True)
In [ ]:
h.hist(atom='CB')
In [ ]:
h.hist2d(residue='CYS',atom1='CB',atom2='N')
In [ ]:
h.hist2d('ASN','HD21','HD22',sd_limit=3)
In [ ]:
h.hist2d('ASN','HD21','HD22',sd_limit=3,ambiguity1=1,ambiguity2=1)
One can also search in BMRB for chemical shift distribution of a particular atom in an amino acid with one or more known set of assigned chemical shift from the same residue. This is especially useful to restrict or define a search range for unassigned side chain atoms with back bone resonances are already assigned.
Here are some examples
In [ ]:
h.conditional_hist(residue='CYS',atom='CB',atomlist=['CA'],cslist=[64.5])
In [ ]:
h.conditional_hist(residue='GLN',atom = 'HE21', atomlist = ['HE22'], cslist=[6.85])
In [ ]: