1. Faheem Mitha
  2. corrmodel-mq

Commits

Faheem Mitha  committed 6e68264

Update paper

  • Participants
  • Parent commits 1a13e5f
  • Branches default

Comments (0)

Files changed (1)

File paper

View file
  • Ignore whitespace
 diff -r 93dca9262560 checkfasta.py
 --- /dev/null
 +++ b/checkfasta.py
-@@ -0,0 +1,101 @@
+@@ -0,0 +1,104 @@
 +def checkfasta(accnum, rss):
 +    import os
 +    from corrmodel.utils import get_conf
 +    names, seqlst = zip(*fasta)
 +    names = [n.split('|')[1] for n in names]
 +    seqdict = dict(zip(names, seqlst))
-+    print seqdict
++    #print "seqdict", seqdict
 +    # remove white space and convert to upper case
 +    #rss = "".join(rss.split())
 +    #rss = rss.upper()
 +    seq_in_rsslst = False
 +    seqcontainsrss = []
++    print "rsslst", rsslst
 +    for accnum in accnumlst:
 +        for rss in rsslst:
 +            #rss = "".join(rss.split())
 +            #rss = rss.upper()
 +            #s = seqlst[i]
-+            seqdict[accnum]
++            s = seqdict[accnum]
++            #print s
 +            sc = complement(s)
 +            #print "forward", rss in s
 +            #print "reversed", rss in sc
 +
 +    #session.execute("SELECT score from %s.model;"%(schema)).fetchall()
 +    rsslst = session.execute("SELECT sequence from %(schema)s.motif inner join %(schema)s.motifgroup on motif.motifgroup_id=motifgroup.id"%{'schema':schema}).fetchall()
++    rsslst = [str(r[0]) for r in rsslst]
 +    session.close()
 +    db.dispose()
 +    #return colnum, model, model_id