[Biopython] PCR primer dimers
Brad Chapman
chapmanb at 50mail.com
Wed Jun 10 13:16:04 UTC 2009
Hi Ogan;
> Does any one know of a module in biopython that does primer
> dimer/hairpin check. I scripted my own pcr primer tiling with a lame
> dimer check function. It does a sliding search of self and cross
> dimerization of primers but I know it is not the proper way.
My suggestion would be to use the primer3 program for primer design
problems. I've used it with a lot of success. Biopython has support
using the eprimer3 commandline program from EMBOSS. Here is some
rough code to get started with:
from Bio.Emboss.Applications import Primer3Commandline
from Bio.Emboss import Primer3
from Bio.Application import generic_run
cl = Primer3Commandline()
cl.set_parameter("-sequence", input_file)
cl.set_parameter("-outfile", output_file)
cl.set_parameter("-numreturn", 1)
generic_run(cl)
h = open(output_file, "r")
primer3_info = Primer3.read(h)
h.close()
# work with primer3_info record
Hope this helps,
Brad
More information about the Biopython
mailing list