Bio::SeqFeature::Primer - Primer Generic SeqFeature
# set up a single primer that can be used in a PCR reaction use Bio::SeqFeature::Primer; # initiate a primer with raw sequence my $primer=Bio::SeqFeature::Primer->new(-seq=>'CTTTTCATTCTGACTGCAACG'); # get the primery tag for the primer # should return Primer my $tag=$primer->primary_tag; # get or set the location that the primer binds to the target at $primer->location(500); my $location=$primer->location(500); # get or set the 5' end of the primer homology, as the primer doesn't # have to be the same as the target sequence $primer->start(2); my $start=$primer->start; # get or set the 3' end of the primer homology $primer->end(19); my $end = $primer->end; # get or set the strand of the primer. Strand should be 1, 0, or -1 $primer->strand(-1); my $strand=$primer->strand; # get or set the id of the primer $primer->display_id('test_id'); my $id=$primer->display_id; # get the tm of the primer. This is calculated for you by the software. # however, see the docs. my $tm = $primer->Tm; print "These are the details of the primer:\n\tTag:\t\t$tag\n\tLocation\t$location\n\tStart:\t\t$start\n"; print "\tEnd:\t\t$end\n\tStrand:\t\t$strand\n\tID:\t\t$id\n\tTm:\t\t$tm\n";
Handle primer sequences. This will allow you to generate a primer object required for a Bio::Seq::PrimedSeq object. This module is designed to integrate with Bio::Tools::Primer3 and Bio::Seq::PrimedSeq.
In addition, you can calculate the melting temperature of the primer.
This module is supposed to implement location and range, presumably through generic.pm, but does not do so yet. However, it does allow you to set primers, and use those objects as the basis for Bio::Seq::PrimedSeq objects.
See also the POD for Bio::Seq::PrimedSeq and Bio::Tools::Nucleotide::Analysis::Primer3
User feedback is an integral part of the evolution of this and other Bioperl modules. Send your comments and suggestions preferably to one of the Bioperl mailing lists. Your participation is much appreciated.
email@example.com - General discussion http://bioperl.org/wiki/Mailing_lists - About the mailing lists
Please direct usage questions or support issues to the mailing list:
rather than to the module maintainer directly. Many experienced and reponsive experts will be able look at the problem and quickly address it. Please include a thorough description of the problem with code and data examples if at all possible.
Report bugs to the Bioperl bug tracking system to help us keep track the bugs and their resolution. Bug reports can be submitted via the web:
Rob Edwards, firstname.lastname@example.org
The original concept and much of the code was written by Chad Matsalla, email@example.com
The rest of the documentation details each of the object methods. Internal methods are usually preceded with a _
Title : new() Usage : $primer = Bio::SeqFeature::Primer(-seq=>sequence_object); Function: Instantiate a new object Returns : A SeqPrimer object Args : You must pass either a sequence object (preferable) or a sequence.
Title : seq() Usage : $seq = $primer->seq(); Function: Return the sequence associated with this Primer. Returns : A Bio::Seq object Args : None.
Title : source_tag() Usage : $tag = $feature->source_tag(); Function: Returns the source of this tag. Returns : A string. Args : If an argument is provided, the source of this SeqFeature is set to that argument.
Title : location() Usage : $tag = $primer->location(); Function: Gets or sets the location of the primer on the sequence Returns : If the location is set, returns that, if not returns 0. Note: At the moment I am using the primer3 notation of location (although you can set whatever you want). In this form, both primers are given from their 5' ends and a length. In this case, the left primer is given from the leftmost end, but the right primer is given from the rightmost end. You can use start() and end() to get the leftmost and rightmost base of each sequence. Args : If supplied will set a location
Title : start() Usage : $start_position = $primer->start($new_position); Function: Return the start position of this Primer. This is the leftmost base, regardless of whether it is a left or right primer. Returns : The start position of this primer or 0 if not set. Args : If supplied will set a start position.
Title : end() Usage : $end_position = $primer->end($new_position); Function: Return the end position of this primer. This is the rightmost base, regardless of whether it is a left or right primer. Returns : The end position of this primer. Args : If supplied will set an end position.
Title : strand() Usage : $strand=$primer->strand() Function: Get or set the strand. Returns : The strand that the primer binds to. Args : If an argument is supplied will set the strand, otherwise will return it. Should be 1, 0 (not set), or -1
Title : display_id() Usage : $id = $primer->display_id($new_id) Function: Returns the display ID for this Primer feature Returns : A scalar. Args : If an argument is provided, the display_id of this primer is set to that value.
Title : Tm() Usage : $tm = $primer->Tm(-salt=>'0.05', -oligo=>'0.0000001') Function: Calculates and returns the Tm (melting temperature) of the primer Returns : A scalar containing the Tm. Args : -salt : set the Na+ concentration on which to base the calculation (default=0.05 molar). : -oligo : set the oligo concentration on which to base the calculation (default=0.00000025 molar). Notes : Calculation of Tm as per Allawi et. al Biochemistry 1997 36:10581-10594. Also see documentation at http://www.idtdna.com/Scitools/Scitools.aspx as they use this formula and have a couple nice help pages. These Tm values will be about are about 0.5-3 degrees off from those of the idtdna web tool. I don't know why. This was suggested by Barry Moore (thanks!). See the discussion on the bioperl-l with the subject "Bio::SeqFeature::Primer Calculating the PrimerTM"
Title : Tm_estimate Usage : $tm = $primer->Tm_estimate(-salt=>'0.05') Function: Calculates and returns the Tm (melting temperature) of the primer Returns : A scalar containing the Tm. Args : -salt set the Na+ concentration on which to base the calculation. Notes : This is an estimate of the Tm that is kept in for comparative reasons. You should probably use Tm instead! This Tm calculations are taken from the Primer3 docs: They are based on Bolton and McCarthy, PNAS 84:1390 (1962) as presented in Sambrook, Fritsch and Maniatis, Molecular Cloning, p 11.46 (1989, CSHL Press). Tm = 81.5 + 16.6(log10([Na+])) + .41*(%GC) - 600/length where [Na+] is the molar sodium concentration, %GC is the %G+C of the sequence, and length is the length of the sequence. However.... I can never get this calculation to give me the same result as primer3 does. Don't ask why, I never figured it out. But I did want to include a Tm calculation here becuase I use these modules for other things besides reading primer3 output. The primer3 calculation is saved as 'PRIMER_LEFT_TM' or 'PRIMER_RIGHT_TM' and this calculation is saved as $primer->Tm so you can get both and average them!