Answered step by step
Verified Expert Solution
Question
1 Approved Answer
this is my oneframe function and i jsut need help with writing a funcition for the longestORF that uses one frame. Thank you! oneframe Write
this is my oneframe function and i jsut need help with writing a funcition for the longestORF that uses one frame. Thank you!
oneframe Write a function on that starts at the position of DNA and searches forward in units of three looking for start codons. When it finds a stat codon, her should take the slice of DNA beginning with that ATG and ask rest for the open reading frame that begins there. It should store that sequence in a list and then continue searching for the next AG start codon and repeat this process. Ultimately, this function returns the list of all ORFs that it found Here are some examples of one in action: >>> EAGTAMAGOGOGTMA) I'ATOTT", "ATGOOGT as oneframe("CCANGTAGAMIGOGO"). AICCCCATALANA CACC L'ATGECATACOMAATTT", "ATGAGAMATTT) def restOFORF (DNA): temp = "ATG" for i in range (3,len (DNA)): codon = DNA[i :i + 3] if codon in ('TGA', 'TAG', 'TAA'] : break temp += codon [0] return temp def oneFrame (DNA): temp = "" lis = [] for i in range (len (DNA)): codon = DNA[i:i + 3] if codon == "ATG": lis.append(restOfORF (DNA[i:])) print (lis) oneframe Write a function on that starts at the position of DNA and searches forward in units of three looking for start codons. When it finds a stat codon, her should take the slice of DNA beginning with that ATG and ask rest for the open reading frame that begins there. It should store that sequence in a list and then continue searching for the next AG start codon and repeat this process. Ultimately, this function returns the list of all ORFs that it found Here are some examples of one in action: >>> EAGTAMAGOGOGTMA) I'ATOTT", "ATGOOGT as oneframe("CCANGTAGAMIGOGO"). AICCCCATALANA CACC L'ATGECATACOMAATTT", "ATGAGAMATTT) def restOFORF (DNA): temp = "ATG" for i in range (3,len (DNA)): codon = DNA[i :i + 3] if codon in ('TGA', 'TAG', 'TAA'] : break temp += codon [0] return temp def oneFrame (DNA): temp = "" lis = [] for i in range (len (DNA)): codon = DNA[i:i + 3] if codon == "ATG": lis.append(restOfORF (DNA[i:])) print (lis)Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started