In [35]:
# Some code to do some thing
# Bahar Alipanahi
# 12/22/2015 


import Bio
import Bio.SeqIO
import Bio.Restriction

In [37]:
total_frags = 0
map_length = []
read_length = []
file_handle = open("/s/fir/c/nobackup/baharpan/Ecoli/sd_0001.maf")
output = open("/s/fir/c/nobackup/baharpan/Ecoli/digeste.valouev", "w")
for read in Bio.SeqIO.parse(file_handle, "maf"):
    output.write(read.id + "\n")
    frags = [str(len(s)/1000) for s in Bio.Restriction.catalyze(read.seq)]
    read_lengths.append(len(read))
    map_lengths.append(len(frags))
    output.write("\tSwaI\tSwaI\t" + "\t".join(frags) + "\n")
    output.write("\n")
output.close()


---------------------------------------------------------------------------
IOError                                   Traceback (most recent call last)
<ipython-input-37-acd467159312> in <module>()
      2 map_length = []
      3 read_length = []
----> 4 file_handle = open("/s/fir/c/nobackup/baharpan/Ecoli/sd_0001.maf")
      5 output = open("/s/fir/c/nobackup/baharpan/Ecoli/digeste.valouev", "w")
      6 for read in Bio.SeqIO.parse(file_handle, "maf"):

IOError: [Errno 13] Permission denied: '/s/fir/c/nobackup/baharpan/Ecoli/sd_0001.maf'

In [38]:
1+2-45+9-9+1


Out[38]:
-41

In [13]:


In [ ]: