Lattice-Automation / seqfold

nucleic acid folding
MIT License
83 stars 12 forks source link

dot_bracket output length does not match sequence length #15

Closed palakpsheth closed 1 year ago

palakpsheth commented 1 year ago

Hello,

For the given sequence ATATCTAGGTAGATAGCTAAGTAAATAACTACGTACATACCTCTCGGTCGATCGCTCAGTCAATCACTCCGTCCATCCCGGGGAGGGCGGAAGGACGGCAGGCCGAGAGCGAAAGAACGACAGACCGCGCAAGCACGCCAGCCCAAAACAACCACACCCCTTTTGTTTATTTCTTGGTTGATTGCTTAGTTAATTACTTC, the output of dot_bracket function with temp=55, the resulting dot_bracket result: ........................................((.(((.((..((((((...........((((((.(((..........))).))))))........))))))..)).))).)) does not have the same length

dodoflyy commented 1 year ago

Same problem:

x = "ACGCTCACCGTGCCCAGTGAGCGA"
y = seqfold.fold(x, temp=65)
print(len(x) == len(seqfold.dot_bracket(y)))

Output:

False
jjti commented 1 year ago

Hey @palakpsheth and @GuoYu-Peng, I believe this bug should be fixed. It required changing the dot_bracket method to take the seq to get its full length

palakpsheth commented 1 year ago

Hey @palakpsheth and @GuoYu-Peng, I believe this bug should be fixed. It required changing the dot_bracket method to take the seq to get its full length

Awesome thank you