[Bioperl-l] frame/strand in [t]blast{n,p,x}

Hilmar Lapp hilmarl@yahoo.com
Wed, 15 Aug 2001 21:39:11 +0200

As for deducing frame and strand of query and subject for blast
reports, the algorithm should be as follows IMO. Please comment so
that we can reach consensus (I'm not perfectly familiar with every
blast variant and how frames are reported).

1) For blastn (DNA against DNA) searches there is no frame. Strand
can be deduced from comparing start and end coordinates of the
query (start > end => strand = -1) and pertains to the query.
2) blastp (protein against protein) searches have neither frame
nor strand.
3) For blastx (6-frame translated DNA query against protein DB)
searches the frame is indicated for each HSP as 
/Frame = ([-+][123])/ in frame coordinates -3..-1,1..3, which we
map in Bioperl to strand +1/-1 and frame 0..2. A subject hit can
have variable strands (and frame) for each HSP (i.e., the strand
for a subject may be ambiguous, but for an HSP it is unambiguous).
The strand (and frame) actually always pertain to the query, not
the subject.
4) tblastn (protein query against 6-frame translated DNA DB): like
3) but strand and frame pertain to the subject, not the query.
Query has neither frame nor strand.
5) tblastx (6-frame translated DNA query against 6-frame
translated DNA DB): frame (and strand) is indicated for each HSP
/Frame = ([-+][123]) \/ ([-+][123])/ in coordinates -3..-1,1..3 to
be mapped to strand +1/-1 and frame 0..2. The first frame
coordinate pertains to the query, the second to the subject

This has the following consequences for correct interpretation of
frame in the BPlite parser:
1) In order to determine whether a single frame indicator pertains
to query or subject the report type (blastx or tblastn) has to be
2) The parser needs to check whether there are two frames reported
3) There is no unambiguous frame or strand for the whole hit
(BPlite::Sbjct, which isn't a SeqFeatureI anyway).

Makes sense?

Hilmar Lapp                              email: hilmarl@yahoo.com
A-1120 Vienna

Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com