Пример #1
0
def main():
	if len(sys.argv)<3:
		print 'Usage: utils_naccess.py 1k2p.rsa DB'
		return

	rsafile = sys.argv[1]
	varname = sys.argv[2]
	na = naccess(rsafile)
	#na.dump()
	#na.dumpResiMap()
	print '[%s]: %s' % (varname, na.getResiList(varname))
Пример #2
0
def main():
	if len(sys.argv) < 3:
		print "Usage python proc_scoreboard.py cg_file rsa_file"
		return

	AAlist = ['A','C','D','E','F','G','H','I','K','L','M','N','P','Q','R','S','T','V','W','Y']
	cgfile = sys.argv[1]
	nafile = sys.argv[2]
	outfile = cgfile+'.nascore'

	print 'loading %s, %s' % (cgfile, nafile)

	na = naccess(nafile)
	alphabet = expandVars([AAlist, na.alphabet])
	#print repr(alphabet)

	cgs = [cg(line.strip(), alphabet) for line in open(cgfile)]

	fo = open(outfile, 'w')
	for c in cgs:
		if len(c.AAgroup) > 1:
			fo.write(c.nascore(na)+'\n')
	fo.close()
Пример #3
0
def main():
	if len(sys.argv) < 3:
		print "Usage python proc_nvboard.py cg_file rsa_file"
		print "python proc_nvboard.py 1k2p.tip.hcg 1k2p.rsa"
		print "output: 1k2p.tip.hcg.nvscore"
		return

	AAlist = ['A','C','D','E','F','G','H','I','K','L','M','N','P','Q','R','S','T','V','W','Y']
	cgfile = sys.argv[1]
	nafile = sys.argv[2]
	outfile = cgfile+'.nvscore'

	#print 'loading %s, %s' % (cgfile, nafile)

	na = naccess(nafile)

	cgs = [cg(line.strip(), '') for line in open(cgfile)]

	fo = open(outfile, 'w')
	for c in cgs:
		if len(c.AAgroup) > 1:
			fo.write(c.nvscore(na)+'\n')
	fo.close()
	print 'finish writing %s.' % outfile
Пример #4
0
def main():
    rsafile = "1k2p.rsa"
    na = naccess(rsafile)
    na.dump()
    na.dumpResiMap()
    print "[DB]: %s" % na.getResiList("DB")