Today we’ll meet at 1.30 pm in aula F pr to finish together our “pick-primers.pl” program. During last lab most of you got Primer3 running with our custom parameters. Primer3 output consists in a list of possible primer pairs.
We want to blast each primer against reference contigs to check how many sequence similar to it are present in the genome. This is a pivotal test to have specific PCRs. To make this we design a subroutine called ‘blast’ that takes as input a sequence (primer) and blast it against the contigs and parses the output returning a list of hints. In particular we consider dangerous those aligment long as the query -2 bp. Thus if our primers is long 20 and the match is 15 we will discard it. If the match with another contig is 18 bases long, we will report this to the user.
Thus we call “longHits” those aligments whose length is >= (primerLength-2). We call “topHit” the longest aligment (exculing itself). Here you are a sample output:
The program we are going to use is /home/geno/tools/pickprimers.pl
#Primer pair 2: 326 bp >Primer2-For 59.909 [longHits=1, topHits=1, topHit=20,contig01727 (20/20 contig00068)] CGCGATTCCTACGCCCGCTT >Primer2-Rev 60.038 [longHits=0, topHits=, topHit=0, (20/20 contig00122)] GGCACCCCTAGCGGCCTACT
PrimerFor has a 1 longHit, and 1 topHit. This means that the longest aligment is >=primerLength-2. Last field (topHit) explains details about the longest aligment: is 20 bases long and matches against contig01727. Finally, in round brackets, we report the self-aligment as a check.
In the following example:
#Primer pair 1: 554 bp >Primer1-For 59.975 [longHits=0, topHits=1, topHit=16,contig00855 (20/20 contig00968)] CGAAGCAGGCGCAGACACCA >Primer1-Rev 59.883 [longHits=306, topHits=99, topHit=20,contig05351 (15/20 contig01498)] AGGGGGAGGGAGGGAGGGAG
we see that primerFor has no “longHits”, and the topHit is just 16 bases long. PrimerRev – on the other hand – is very aspecific and matches 99 times with full length (20/20). It should be discarded even if primerFor is good.
If you want to test a primer, do your own blast:
echo AGGGGGAGGGAGGGAGGGAG | /home/geno/blast/bin/blastall -p blastn -d /home/geno/tools/contigs.fna -m 8
pickprimer.pl advanced features
We discussed about parameters and hard-coded constants during past lessons… I added the possibility of optional
parameters: Parameters: contig1 dir1 contig2 dir2 [tm] [prLen] [pcrSize]
So you can specify Tm, primerLength and PCR-size, but if you don’t they are taken from the hard-coded defaults.
pickprimer now saves a file with all the information (not only the output). We call this file “log” and it’s called “log-contig1dir1-contig2dir2.txt“.
Create your primers and choose the best
Choose the best primer pair and save them in our new database.