public
Description: repository for the code featured in the blog
Homepage: http://python.genedrift.org
Clone URL: git://github.com/nuin/beginning-python-for-bioinformatics.git
100755 14 lines (11 sloc) 0.248 kb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
import sys
import re
 
gbfile = open(sys.argv[1], 'r').readlines()
 
sequence = ''
issequence = False
for line in gbfile:
    if issequence == True:
        sequence += line
    elif line.find('ORIGIN') >= 0:
        issequence = True
 
print sequence