Repository 'shm_csr'
hg clone https://radegast.galaxyproject.org/repos/davidvanzessen/shm_csr

Changeset 17:b95fa7e426c3 (2016-11-24)
Previous changeset 16:4e596473c25c (2016-11-23) Next changeset 18:949a30f04d9b (2016-11-28)
Commit message:
Uploaded
modified:
shm_csr.py
b
diff -r 4e596473c25c -r b95fa7e426c3 shm_csr.py
--- a/shm_csr.py Wed Nov 23 09:05:40 2016 -0500
+++ b/shm_csr.py Thu Nov 24 10:24:19 2016 -0500
[
@@ -247,12 +247,9 @@
 
 
 def get_xyz(lst, gene, f, fname):
-
- x = int(round(f(lst)))
+ x = round(round(f(lst), 1))
  y = valuedic[gene + "_" + fname]
  z = str(round(x / float(y) * 100, 1)) if y != 0 else "0"
- if gene == "unmatched":
- print x, y, z
  return (str(x), str(y), z)
 
 dic = {"RGYW": RGYWCount, "WRCY": WRCYCount, "WA": WACount, "TW": TWCount}
@@ -282,7 +279,7 @@
 # for testing
 seq_motif_file = outfile[:outfile.rindex("/")] + "/motif_per_seq.txt"
 with open(seq_motif_file, 'w') as o:
- o.write("ID\tRGYWC\tWRCY\tWA\tTW\n")
+ o.write("ID\tRGYW\tWRCY\tWA\tTW\n")
  for ID in IDlist:
  #o.write(ID + "\t" + str(round(RGYWCount[ID], 2)) + "\t" + str(round(WRCYCount[ID], 2)) + "\t" + str(round(WACount[ID], 2)) + "\t" + str(round(TWCount[ID], 2)) + "\n")
  o.write(ID + "\t" + str(RGYWCount[ID]) + "\t" + str(WRCYCount[ID]) + "\t" + str(WACount[ID]) + "\t" + str(TWCount[ID]) + "\n")