Exemplo n.º 1
0
def did2count(hmmout, pids=False):
  pid2pfamdomains = pfam.read_hmmout(hmmout)
  if not pids: keys = pid2pfamdomains.keys()
  else: keys = pids
  did2count = {}
  for pid in keys:
    if not pid2pfamdomains.has_key(pid): continue
    for did in list(set([d.get_attr("hmm_name") for d in pid2pfamdomains[pid]])):
      if not did2count.has_key(did): did2count[did] = 0
      did2count[did] += 1
  return did2count
Exemplo n.º 2
0
def did2count(hmmout, pids=False):
    pid2pfamdomains = pfam.read_hmmout(hmmout)
    if not pids: keys = pid2pfamdomains.keys()
    else: keys = pids
    did2count = {}
    for pid in keys:
        if not pid2pfamdomains.has_key(pid): continue
        for did in list(
                set([d.get_attr("hmm_name") for d in pid2pfamdomains[pid]])):
            if not did2count.has_key(did): did2count[did] = 0
            did2count[did] += 1
    return did2count
Exemplo n.º 3
0
def main(args):
    pid2domains = pfam.read_hmmout(args['hmmoutfile'])
    for pid, domains in pid2domains.iteritems():
        domains2clan(domains)
Exemplo n.º 4
0
def main( args ):
  pid2domains = pfam.read_hmmout(args['hmmoutfile'])
  for pid, domains in pid2domains.iteritems():
    domains2clan(domains)
def main( args ):
  pid2domains = pfam.read_hmmout(args['hmmoutfile'])
  for pid, domains in pid2domains.iteritems():
    sys.stderr.write("\r" + pid + " "*20)
    arr = domains2arrangement(domains)
    print pid + "\t" + arr          
def main(args):
    pid2domains = pfam.read_hmmout(args['hmmoutfile'])
    for pid, domains in pid2domains.iteritems():
        sys.stderr.write("\r" + pid + " " * 20)
        arr = domains2arrangement(domains)
        print pid + "\t" + arr