[Bioperl-l] internal code review of Bio::Search

Jason Stajich jason@cgt.mc.duke.edu
Tue, 5 Feb 2002 12:37:52 -0500 (EST)

[frac_identity question]
When people are interested in what fraction of a HSP is identical
or conserved - one is typically looking for the fraction identical in the
HSP or relative to the whole sequence?

I assume relative to just the portion that is participating the HSP, but
just wanted to make sure... Does anyone else have code that calculates
this so I can validate my implementation - I have been doing
it against the entire length of the hit/query not the smaller portion
in the HSP which I believe is wrong and am currently fixing that.

[length question]

In the Bio::Search::HSP objects I think there are some confusing parts wrt
to length - any help in nomeclature or docs would be appreciated.

(part of Hilmar's original SimilarityPair/FeaturePair which I have kept
$hsp->query->seqlength     - length of the entire query piece
$hsp->query->length        - length of the query participating in the HSP
"" ditto s/query/hit/

(my added method to get at the HSP length)
$hsp->hsp_length           - length of the HSP (which includes gaps added
                             from query and hit)

(Steve's HSPI length methods - see Bio::Search::HSP::HSPI for docs)
$hsp->length('total')      - length of the HSP
$hsp->length('query')      - length of the query in the HSP
$hsp->length('hit')        - length of the hit in the HSP

Jason Stajich
Duke University