蟒蛇方案的实现
tmscoring的Python项目详细描述
TM取芯
python实现TMscore程序来比较相同蛋白质的结构。
用法:
我们提供了三个类,TMscoring
、Sscoring
和RMSDscoring
,它们的默认值不同
优化得分。
它们使用到两个PDB文件的文件路径进行初始化:
alignment = tmscoring.TMscore('structure1.pdb', 'structure2.pdb')
# Find the optimal alignment
alignment.optimise()
# Get the TM score:
alignment.tmscore(**alignment.get_current_values())
# Get the TM local scores:
alignment.tmscore_samples(**alignment.get_current_values())
# RMSD of the protein aligned according to TM score
alignment.rmsd(**alignment.get_current_values())
# Returns the transformation matrix between both structures:
alignment.get_matrix(**alignment.get_current_values())
# Save the aligned files:
alignment.write(outputfile='aligned.pdb', append=True)
这些结构可以通过索引(默认)进行匹配,或者使用Smith Waterman执行全局序列对齐 如果比赛得分为2,失配为-1,开局罚-0.5分,延长罚-0.1分。
实用功能:
get_tm(path_to_pdb1, path_to_pdb2)
和get_rmsd(pdb1, pdb2)
是计算TM评分或RMSD的简单包装。
有什么不同?
tmscoring是一个python库,可以方便地公开所有必需的变量。 这就消除了分析文件的必要性。
此外,最小化引擎是MINUIT's Migrad,一个强大的、健壮的无导数最小化算法,
经过粒子物理学家数十年的严格测试。
在我们的测试中,tmscoring
得到的分数与上游的TMscore
相同或稍好。