python-gaussian网络模型
pygnm的Python项目详细描述
用于高斯网络模型计算的python模块,具有集成的绘图功能。
python是一种面向对象的脚本语言,具有强大的标准和丰富的第三方库。它适合于快速灵活的代码开发。如果您不熟悉python,但知道编程,那么您可以按照python教程在几个小时内学会使用这个包。
pygnm是纯pyton代码,依赖于广泛使用的数字和图形包。所有GNM便利性和绘图功能都在本教程中进行了记录和说明。pygnm可用于分析单个蛋白质结构(参见教程)和执行多个结构的自动分析(当然还有一些python代码)。
参考文献
- 用单参数调和势直接评价蛋白质的热涨落 I.Bahar,A.R.Atilgan和B.Erman Folding&Design 21973-1811997年。
- 折叠蛋白质的高斯动力学 Haliloglu、T.Bahar、I.和Erman、B.Phys。修订版利特。793090-30931997年。
- Wikipedia article
许可证
这个python包是在gnu通用公共许可下发布的。
依赖关系
生物疗法 纽比 短发 matplotlib(可选,但绘图功能需要)
安装
Linux
提取tarball内容并运行setup.py,如下所示: 焦油-xzf ppygnm-0.x.tar.gz 光盘Pygnm-0.x python setup.py安装 最后一步可能需要根访问权限。
窗口
使用可执行文件安装pygnm。
教程
本教程也包含在pygnm包中。
"""This is an example use of PyGNM, and is distributed with PyGNM package. This example assumes that you have installed Matplotlib. A ubiquitin structureis used in this example. (PDB id 2BWF, Lowe et al., 2006 Acta Crystallogr., Sect. D 62:177) """ # Import plotting library >>> import matplotlib.pyplot as pl # Import GNM module from pygnm package >>> from pygnm import GNM # Initialize a GNM object # Please make sure that the PDB file is in the current working directory # You may need to download this, or another, PDB file # Both .pdb and pdb.gz extensions are handled >>> gnm = GNM('2BWF.pdb.gz') # Select residues to be included in the model # Some examples are # "*" and "*:*" # select all chains and residues # # "A:x,y-z,w D:k-l G:*" # select residues x, y to z (inclusive), # and w in chain A # and residues k to l (inclusive) in chain D # and all residues in chain G # # "A B" # select all residues in chains A and B # # "*:5-25,50-100" # select same set of residues in all chains >>> gnm.select_residues('A:1-70') # Build Kirchhoff matrix # cutoff=10., gamma=1.0 are default values, and may be omitted >>> gnm.set_kirchhoff(cutoff=10., gamma=1.0) # Calculate GNM modes # An optional parameter is n_modes # If you want to see only 20 nonzero modes, you can set n_modes=20 # gnm.calculate_modes(n_modes=20) >>> gnm.calculate_modes() # CONVENIENCE FUNCTIONS # Get first 20 eigenvalues, including the zero eigenvalue >>> gnm.get_eigenvalues( range(20) ) # Get first eigenvector with a nonzero eigenvalue >>> gnm.get_eigenvectors(1) # Get first and second modes (eigenvector^2) with nonzero eigenvalues >>> gnm.get_modes( [1, 2] ) # Get covariance matrix (pseudo-inverse of Kirchhoff) >>> gnm.get_covariance() # Get cross-correlations calclated using first 9 modes (w/ nonzero eigenvalues) >>> gnm.get_cross_correlations( range(1, 10)) # PLOTTING FUNCTIONS # Note that before each plot command, pl.figure() function is called # to prevent plotting over the previous figure. # Plot eigenvector shape >>> pl.figure() >>> gnm.plot_eigenvector(1) # Plot mode shape >>> pl.figure() >>> gnm.plot_mode(1) # Plot bfactors from PDB file >>> pl.figure() >>> gnm.plot_bfactors() # Plot GNM square-fluctuations >>> pl.figure() >>> gnm.plot_square_fluctuations() # Plot GNM square-fluctuations for low frequence nonzero 10 modes >>> pl.figure() >>> gnm.plot_square_fluctuations(indices=range(1, 11)) # Plot GNM cross-correlations >>> pl.figure() >>> gnm.show_cross_correlations() # Plot GNM cross-correlations for low frequence nonzero 10 modes >>> pl.figure() >>> gnm.show_cross_correlations(indices=range(1, 11)) # WRITE PDB # Write a PDB file with square fluctuations on beta column >>> gnm.write_pdb( bfactors=gnm.get_square_fluctuations(indices=range(1, 11)) )