pKaTool/Ghosts/Chemical_shift.py
def parseCSP():
	'''
	Parse the options from the command line
	'''

	parser=optparse.OptionParser()
	
	#
	#set optparse options
	#
	parser.add_option(
		'--pdb',
		dest='pdb',
		default=None,
		type='string',
		help='<name of the pdb file>',
		)
	parser.add_option(
		'--nucleus',
		dest='nucleus',
		default='N',
		type='choice',
		choices=('N','H',),
		help='<nucleus type (N, H)>'
		)
	parser.add_option(
		'--method',
		dest='method',
		default='Coulomb',
		type='choice',
		choices=('Coulomb','PBE',),
		help='<method used for calculating electric field (Coulomb, PBE)>'
		)
	parser.add_option(
		'--pKaDict',
		dest='pKaDict',
		type='string',
		default="{}",
		help='<dictionary of pKa values {titGroup:pKa,...}>'
		)
	parser.add_option(
		'--protDiel',
		dest='protDiel',
		type='float',
		default=4.0,
		help='<protein dielectric constant>'
		)
	parser.add_option(
		'--solvDiel',
		dest='solvDiel',
		type='float',
		default=80.0,
		help='<solvent dielectric constant>'
		)
		
	(options, args,) = parser.parse_args()
	##
	##parse optparse options
	##
	pdb = options.pdb
	nucleus = options.nucleus
	method = options.method
	pKaDict = eval(options.pKaDict)
	protDiel = options.protDiel
	solvDiel = options.solvDiel#
	
	return pdb, nucleus, method, pKaDict, protDiel, solvDiel

	Parse the options from the command line
	
Parse the options from the command line
Parse the options from the command line
def parseCSP():
	parser=optparse.OptionParser()
	set optparse options
	parser.add_option(
		'--pdb',
		dest='pdb',
		default=None,
		type='string',
		help='<name of the pdb file>',
		)
	parser.add_option(
		'--nucleus',
		dest='nucleus',
		default='N',
		type='choice',
		choices=('N','H',),
		help='<nucleus type (N, H)>'
		)
	parser.add_option(
		'--method',
		dest='method',
		default='Coulomb',
		type='choice',
		choices=('Coulomb','PBE',),
		help='<method used for calculating electric field (Coulomb, PBE)>'
		)
	parser.add_option(
		'--pKaDict',
		dest='pKaDict',
		type='string',
		default="{}",
		help='<dictionary of pKa values {titGroup:pKa,...}>'
		)
	parser.add_option(
		'--protDiel',
		dest='protDiel',
		type='float',
		default=4.0,
		help='<protein dielectric constant>'
		)
	parser.add_option(
		'--solvDiel',
		dest='solvDiel',
		type='float',
		default=80.0,
		help='<solvent dielectric constant>'
		)
	(options, args,) = parser.parse_args()
	parse optparse options
	pdb = options.pdb
	nucleus = options.nucleus
	method = options.method
	pKaDict = eval(options.pKaDict)
	protDiel = options.protDiel
	solvDiel = options.solvDiel
	return pdb, nucleus, method, pKaDict, protDiel, solvDiel
def parseCSP ( ) : parser = optparse . OptionParser ( ) parser . add_option ( '--pdb' , dest = 'pdb' , default = None , type = 'string' , help = '<name of the pdb file>' , ) parser . add_option ( '--nucleus' , dest = 'nucleus' , default = 'N' , type = 'choice' , choices = ( 'N' , 'H' , ) , help = '<nucleus type (N, H)>' ) parser . add_option ( '--method' , dest = 'method' , default = 'Coulomb' , type = 'choice' , choices = ( 'Coulomb' , 'PBE' , ) , help = '<method used for calculating electric field (Coulomb, PBE)>' ) parser . add_option ( '--pKaDict' , dest = 'pKaDict' , type = 'string' , default = "{}" , help = '<dictionary of pKa values {titGroup:pKa,...}>' ) parser . add_option ( '--protDiel' , dest = 'protDiel' , type = 'float' , default = 4.0 , help = '<protein dielectric constant>' ) parser . add_option ( '--solvDiel' , dest = 'solvDiel' , type = 'float' , default = 80.0 , help = '<solvent dielectric constant>' ) ( options , args , ) = parser . parse_args ( ) pdb = options . pdb nucleus = options . nucleus method = options . method pKaDict = eval ( options . pKaDict ) protDiel = options . protDiel solvDiel = options . solvDiel return pdb , nucleus , method , pKaDict , protDiel , solvDiel
Parse the options from the command line
Parse the options from the command line
'''
	Parse the options from the command line
	''' # #set optparse options # ## ##parse optparse options ## #