Ghost/Chemical_shift.py
def important_titgroup(self,level=0.5):
		'''For all nuclei finds the most influential titratable groups on a given pH value'''
		
		if not os.path.isdir(os.path.join(os.getcwd(),'figures/')):
			os.system('mkdir figures')
		dir_name=os.path.join(os.getcwd(),'figures/')
		
		CS={}
		file_name=dir_name+'important_titgroup_%9s.txt'%(self.pdb)
		fd=open(file_name,'w')
		for residue in self.residues_below:
			print >> fd, '\nResidue:\n',residue
			diel=self.ultimate_diel[residue]
			print >> fd, 'diel_const: ', diel
			print >> fd, '\nTit group    value\n'
			CS[residue]={}
			for titgroup in self.titgroups:
				if self.dict_CS[diel][residue][titgroup]!=(0.00 or None):
					if (titgroup[-3:]=='GLU') or (titgroup[-5:]=='NTERM') or (titgroup[-5:]=='CTERM') or (titgroup[-3:]=='ASP'):
						CS[residue][titgroup]=abs(self.dict_CS[diel][residue][titgroup])
						if CS[residue][titgroup]>level:
							print >> fd, '%12s %4.2f'%(titgroup,CS[residue][titgroup]) 
				else:
					pass
			
		fd.close()
For all nuclei finds the most influential titratable groups on a given pH value
For all nuclei finds the most influential titratable groups on a given pH value
For all nuclei finds the most influential titratable groups on a given pH value
def important_titgroup(self,level=0.5):
		if not os.path.isdir(os.path.join(os.getcwd(),'figures/')):
			os.system('mkdir figures')
		dir_name=os.path.join(os.getcwd(),'figures/')
		CS={}
		file_name=dir_name+'important_titgroup_%9s.txt'%(self.pdb)
		fd=open(file_name,'w')
		for residue in self.residues_below:
			print >> fd, '\nResidue:\n',residue
			diel=self.ultimate_diel[residue]
			print >> fd, 'diel_const: ', diel
			print >> fd, '\nTit group    value\n'
			CS[residue]={}
			for titgroup in self.titgroups:
				if self.dict_CS[diel][residue][titgroup]!=(0.00 or None):
					if (titgroup[-3:]=='GLU') or (titgroup[-5:]=='NTERM') or (titgroup[-5:]=='CTERM') or (titgroup[-3:]=='ASP'):
						CS[residue][titgroup]=abs(self.dict_CS[diel][residue][titgroup])
						if CS[residue][titgroup]>level:
							print >> fd, '%12s %4.2f'%(titgroup,CS[residue][titgroup]) 
				else:
					pass
		fd.close()
def important_titgroup ( self , level = 0.5 ) : if not os . path . isdir ( os . path . join ( os . getcwd ( ) , 'figures/' ) ) : os . system ( 'mkdir figures' ) dir_name = os . path . join ( os . getcwd ( ) , 'figures/' ) CS = { } file_name = dir_name + 'important_titgroup_%9s.txt' % ( self . pdb ) fd = open ( file_name , 'w' ) for residue in self . residues_below : print >> fd , '\nResidue:\n' , residue diel = self . ultimate_diel [ residue ] print >> fd , 'diel_const: ' , diel print >> fd , '\nTit group    value\n' CS [ residue ] = { } for titgroup in self . titgroups : if self . dict_CS [ diel ] [ residue ] [ titgroup ] != ( 0.00 or None ) : if ( titgroup [ - 3 : ] == 'GLU' ) or ( titgroup [ - 5 : ] == 'NTERM' ) or ( titgroup [ - 5 : ] == 'CTERM' ) or ( titgroup [ - 3 : ] == 'ASP' ) : CS [ residue ] [ titgroup ] = abs ( self . dict_CS [ diel ] [ residue ] [ titgroup ] ) if CS [ residue ] [ titgroup ] > level : print >> fd , '%12s %4.2f' % ( titgroup , CS [ residue ] [ titgroup ] ) else : pass fd . close ( )
For all nuclei finds the most influential titratable groups on a given pH value
For all nuclei finds the most influential titratable groups on a given pH value
'''For all nuclei finds the most influential titratable groups on a given pH value'''
self
level