1
$\begingroup$

Seq = AAAAAAAAAAATTTTTTTTTTTGAATTCCCCCCCCCCCGGGGGGGGGGG

Restriction site = GAATTC

I want to cut the sequence at GA/ATTC

I tried split method in python but It does not cut at GA/ATTC. Please help

$\endgroup$
5
  • 4
    $\begingroup$ Have you looked up the documentation on working with restriction enzymes in biopython? biopython.org/DIST/docs/cookbook/Restriction.html#1.3 $\endgroup$
    – Devon Ryan
    Nov 8 '20 at 12:06
  • $\begingroup$ Nice documentation It really helped me. Thanks. $\endgroup$ Nov 8 '20 at 13:44
  • 3
    $\begingroup$ If you're able to do this after actually reading the documentation then please post a working example as an answer for others. $\endgroup$
    – Devon Ryan
    Nov 8 '20 at 14:01
  • $\begingroup$ The obvious bare native Python 'AAAAAAAAAAATTTTTTTTTTTGAATTCCCCCCCCCCCGGGGGGGGGGG'.split('GAATTC') produces what I expect. $\endgroup$
    – tripleee
    Nov 10 '20 at 6:03
  • 1
    $\begingroup$ @tripleee, your solution would not reflect the "true biology" The restriction enzyme cuts within the recognized bases and the two resulting fragments would contain a part (different parts obviously) of the restriction site. $\endgroup$
    – haci
    Nov 10 '20 at 14:45
3
$\begingroup$
import Bio
from Bio.Seq import Seq
my_seq = Seq("aaaaaaaaaaatttttttttttgaattccccccccccggggggggggg")
from Bio.Restriction import *
print(EcoRI.search(my_seq))
print(EcoRI.catalyse(my_seq))

Actully the EcoRI cuts the DNA after G in restriction site GAATTC.

$\endgroup$
1
  • $\begingroup$ Okay my apologies, optical analysis is one of the reasons why bioinformatics is so important. You can mark your post as 'accepted'. $\endgroup$
    – M__
    Nov 10 '20 at 12:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.