Skip Menu |

This queue is for tickets about the Boulder CPAN distribution.

Report information
The Basics
Id: 65346
Status: new
Priority: 0/
Queue: Boulder

People
Owner: Nobody in particular
Requestors: david.bauer [...] bayer.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: NCBI.pm match string wrong
Date: Tue, 1 Feb 2011 14:10:40 +0100
To: bug-Boulder [...] rt.cpan.org
From: david.bauer [...] bayer.com
Hi, I was happy to find this light weighted module to quickly parse BLAST results. But the absolute extraction of the match string (which is already in the code marked as UGLY ;-)) did not work reliably. Most the times it starts at position 12 but, depending on the length of the start and end position numbers, it can also be 11 or 13. So I added some lines to get the start position from the start position of the Query sequence string. Here is the diff: ########################################### diff NCBI.pm NCBI.pm.ori 148d147 < my $offset; 247,254d245 < # get absolute position of query sequence to grab match string < my $test = $_; < $test =~ s/Query: //; < my @test = split(//,$test); < $offset=7; < foreach my $test (@test) { < if (($test =~ /\d/) || ($test =~ /\s/)) {$offset++} else {last} < } 269,270c260 < # This did not work. Modified to get offset from Query line. DB 01.01.2011 < $match .= substr($_,$offset,60) if $query; --- Show quoted text
> $match .= substr($_,12,60) if $query;
############################################## Kind regards, David. Freundliche Grüße / Best Regards David Bauer Show quoted text
_________________________________________ Bayer Schering Pharma Aktiengesellschaft BSP-GDD-CP-TS-BMB Berlin, S110, 02, 707 Phone: +49 30 468 12657 Fax: +49 30 468 92657 E-mail: david.bauer@bayer.com Web: http://www.bayerscheringpharma.de Vorstand: Andreas Fibig, Vorsitzender | Andreas Busch, Ulrich Köstlin, Kemal Malik, Bernd Metzner Vorsitzender des Aufsichtsrats: Richard Pott Sitz der Gesellschaft: Berlin | Eintragung: Amtsgericht Charlottenburg HRB 283 B