简体   繁体   English

Python 找到最长的 ORF

[英]Python finding the longest ORF

Can someone show me a straightforward solution for how to calculate the longest open reading frame (ORF) > 30bp in length in a DNA sequence?有人可以告诉我一个简单的解决方案,用于计算 DNA 序列中最长的开放阅读框 (ORF) > 30bp 的长度吗? ATG is the start codon (ie, the beginning of an ORF) and TAG, TGA, and TAA are stop codons (ie, the end of an ORF). ATG 是起始密码子(即 ORF 的开头),TAG、TGA 和 TAA 是终止密码子(即 ORF 的结尾)。 Without the use of BioPython.不使用 BioPython。

This regex might be able to do the job:这个正则表达式可能能够完成这项工作:

ATG(...){30,}(TAG|TGA|TAA)

(...) is a three letter codon, that is matched 30 or more times with {30,} and stops whenever it finds one of (TAG|TGA|TAA) . (...)是一个三字母密码子,与 {30,} 匹配 30 次或更多次,并在找到(TAG|TGA|TAA)之一时停止。

This regex can help you find all ORF and now you just have to find the longest which should be trivial.这个正则表达式可以帮助你找到所有的 ORF,现在你只需要找到最长的那个应该是微不足道的。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM