output_SW.py
def reversecomplement(nucstring):
    '''Helper method for getvals: input is nucleotide sequence, returns its reverse complement'''
    bases_dictionary = {'a': 't', 't': 'a', 'c': 'g', 'g': 'c', 'n': 'n'}
    revcomp = ''
    try:
        for pos in reversed(xrange(1, len(nucstring))):
            revcomp = revcomp + str((bases_dictionary[nucstring[pos-1].lower()]))
        return revcomp
    except Exception as e:
        # print (e)
        for pos in reversed(range(1, len(nucstring))):
            revcomp = revcomp + str((bases_dictionary[nucstring[pos-1].lower()]))
        return revcomp
Helper method for getvals: input is nucleotide sequence, returns its reverse complement
Helper method for getvals: input is nucleotide sequence, returns its reverse complement
Helper method for getvals : input is nucleotide sequence returns its reverse complement
def reversecomplement(nucstring):
    bases_dictionary = {'a': 't', 't': 'a', 'c': 'g', 'g': 'c', 'n': 'n'}
    revcomp = ''
    try:
        for pos in reversed(xrange(1, len(nucstring))):
            revcomp = revcomp + str((bases_dictionary[nucstring[pos-1].lower()]))
        return revcomp
    except Exception as e:
        for pos in reversed(range(1, len(nucstring))):
            revcomp = revcomp + str((bases_dictionary[nucstring[pos-1].lower()]))
        return revcomp
def reversecomplement ( nucstring ) : bases_dictionary = { 'a' : 't' , 't' : 'a' , 'c' : 'g' , 'g' : 'c' , 'n' : 'n' } revcomp = '' try : for pos in reversed ( xrange ( 1 , len ( nucstring ) ) ) : revcomp = revcomp + str ( ( bases_dictionary [ nucstring [ pos - 1 ] . lower ( ) ] ) ) return revcomp except Exception as e : for pos in reversed ( range ( 1 , len ( nucstring ) ) ) : revcomp = revcomp + str ( ( bases_dictionary [ nucstring [ pos - 1 ] . lower ( ) ] ) ) return revcomp
Helper method for getvals: input is nucleotide sequence, returns its reverse complement
Helper method for getvals : input is nucleotide sequence returns its reverse complement
'''Helper method for getvals: input is nucleotide sequence, returns its reverse complement''' # print (e)
nucstring