[Bioperl-l] Hsp_hit-from
Joshua Udall
jaudall at gmail.com
Thu Oct 11 23:34:18 EDT 2007
Thanks! For some reason I was stuck on the idea that it would be different
with an xml file. I'm glad it's not ...
On 10/11/07, Chris Fields <cjfields at uiuc.edu> wrote:
>
>
> On Oct 11, 2007, at 7:51 PM, Joshua Udall wrote:
>
> > Bioperl -
> >
> > I'm parsing an XML blast output using SearchIO and the usual fields
> > seem to
> > work fine.
> >
> > print $result->query_name . "\t" . $hit->name . "\n";
> >
> > However, I'm curious as to the 5' position distribution of my
> > hits. So I'd
> > like to access this data field <Hsp_query-from> in the xml output
> > file. I
> > searched both the mailing lists and the Search docs including
> > *Bio::Search::Hit::HitI,
> > *but I can't seem to find an example of someone accessing this data
> > field.
> > Perhaps, I missed it, but do any of you have any suggestions as to
> > how I
> > might get at the <Hsp_query-from> for each hit? Thanks.
> >
> > Josh
>
> That tag (as well as related tags) are mapped to start(), end(), and
> strand() in the HSP objects. To access the relevant data pass
> 'query' or 'hit' to the method, so for the query use: $hsp->start
> ('query') or $hsp->end('query').
>
> Note: in BioPerl all location starts are less than the end (strand
> determines the orientation for DNA).
>
> chris
>
More information about the Bioperl-l
mailing list