Mercurial > repos > davidvanzessen > mutation_analysis
comparison gene_identification.py @ 61:64e6a7803e07 draft
Uploaded
| author | davidvanzessen |
|---|---|
| date | Fri, 18 Mar 2016 08:17:08 -0400 |
| parents | 1558fbbc19ef |
| children | 4262e880472d |
comparison
equal
deleted
inserted
replaced
| 60:1558fbbc19ef | 61:64e6a7803e07 |
|---|---|
| 197 elif cg3hits >= cg1hits and cg3hits >= cg2hits and cg3hits >= cg4hits: #cg3 gene | 197 elif cg3hits >= cg1hits and cg3hits >= cg2hits and cg3hits >= cg4hits: #cg3 gene |
| 198 o.write(ID + "\tcg3\t" + str(int(cg3hits / varsInCG * 100)) + "\t" + str(int(cghits / possiblecg * 100)) + "\t" + start_location[ID + "_cg"] + "\n") | 198 o.write(ID + "\tcg3\t" + str(int(cg3hits / varsInCG * 100)) + "\t" + str(int(cghits / possiblecg * 100)) + "\t" + start_location[ID + "_cg"] + "\n") |
| 199 else: #cg4 gene | 199 else: #cg4 gene |
| 200 o.write(ID + "\tcg4\t" + str(int(cg4hits / varsInCG * 100)) + "\t" + str(int(cghits / possiblecg * 100)) + "\t" + start_location[ID + "_cg"] + "\n") | 200 o.write(ID + "\tcg4\t" + str(int(cg4hits / varsInCG * 100)) + "\t" + str(int(cghits / possiblecg * 100)) + "\t" + start_location[ID + "_cg"] + "\n") |
| 201 else: #its a cm gene | 201 else: #its a cm gene |
| 202 o.write(ID + "\tcm\t0\t" + str(int(cmhits / possiblecm * 100)) + "\t" + start_location[ID + "_cg"] + "\n") | 202 o.write(ID + "\tcm\t100\t" + str(int(cmhits / possiblecm * 100)) + "\t" + start_location[ID + "_cg"] + "\n") |
| 203 seq_write_count += 1 | 203 seq_write_count += 1 |
| 204 | 204 |
| 205 print "Time: %i" % (int(time.time() * 1000) - starttime) | 205 print "Time: %i" % (int(time.time() * 1000) - starttime) |
| 206 | 206 |
| 207 print "Number of sequences written to file:", seq_write_count | 207 print "Number of sequences written to file:", seq_write_count |
