[Bioperl-l] pb with remote method in Bio::Tools::Blast

Catherine Letondal letondal@pasteur.fr
Mon, 12 Nov 2001 18:05:27 +0100


Elia Stupka wrote:
> > # use local program golden from N. Joly to fetch a sequence locally my
> > $Seq_in = Bio::SeqIO->new (-file => 'golden sp:TAUD_ECOLI | ', -format
> > => 'swiss');
> 
> It sounds to me like your local program is returning html, 

No :-) (see the posting_parameters content I have added in my previous
email, it's correct).

> and thus it cannot be parsed, you are telling it parse swissprote format, but the file
> you are giving it is not in swissprot format. The format parameter is not
> to be confused with a database parameter, it merely describes the sequence
> format used. I think in this case you want your golden script to take away
> all the rest and just give back the fasta sequence, and then change the
> -format paramter to "fasta".

As I said in my previous message, the problem is after. Another example with a fasta
formatted sequence yields exactly the same behaviour (the blast HTML output
really does not contain any BLASTP string that is searched for by the Webblast 
_removeJunkTagAndText method) :


use Bio::Tools::Blast;
use Bio::SeqIO;

my $Seq_in = Bio::SeqIO->new (-file   => $ARGV[0], -format => 'fasta');
print STDERR "fetching seq...\n";
my $seq = $Seq_in->next_seq();
print STDERR $seq->seq, "\n";
my %runParam = ( -method   => 'remote',
		 -prog     => 'blastp',
		 -database =>'swissprot',
		 -seqs     => [ $seq ],  # Bio::Seq.pm object(s)
		 );
print STDERR "running blast...\n";
my $report = Bio::Tools::Blast->new( -run     => \%runParam,
				       -parse   => 1
				       );
foreach my $hit ($report->hits) {
 printf "%s\t %.1e\t %d\t %.2f\t %d\n",
                            $hit->name, $hit->expect, $hit->num_hsps,
                            $hit->frac_identical, $hit->gaps;
}

==> outputs:

fetching seq...
SERLSITPLGPYIGAQISGADLTRPLSDNQFEQLYHAVLRHQVVFLRDQAITPQQQRALAQRFGELHIHPVYPHAEGVDEIIVLDTHNDNPPDNDNWHTDVTFIETPPAGAILAAKELPSTGGDTLWTSGIAAYEALSVPFRQLLSGLRAEHDFRKSFPEYKYRKTEEEHQRWREAVAKNPPLLHPVVRTHPVSGKQALFVNEGFTTRIVDVSEKESEALLSFLFAHITKPEFQVRWRWQPNDIAIWDNRVTQHYANADYLPQRRIMHRATILGDKPFYRAG
running blast...
-------------------- EXCEPTION --------------------
MSG: Blast file TAUD_ECOLI.blastp2.swissprot.temp.html is incomplete: can't find program name.
Possibly an unrecognized report format.
STACK Bio::Tools::Blast::Run::Webblast::_blast /local/lib/perl5/site_perl/5.6.0/Bio/Tools/Blast/Run/Webblast.pm:1175
STACK Bio::Tools::Blast::Run::Webblast::blast_remote /local/lib/perl5/site_perl/5.6.0/Bio/Tools/Blast/Run/Webblast.pm:580
STACK Bio::Tools::Blast::_run_remote /local/lib/perl5/site_perl/5.6.0/Bio/Tools/Blast.pm:1234
STACK Bio::Tools::Blast::run /local/lib/perl5/site_perl/5.6.0/Bio/Tools/Blast.pm:1169
STACK Bio::Tools::SeqAnal::_initialize /local/lib/perl5/site_perl/5.6.0/Bio/Tools/SeqAnal.pm:279
STACK Bio::Root::Object::new /local/lib/perl5/site_perl/5.6.0/Bio/Root/Object.pm:474
STACK toplevel b.pl:20
-------------------------------------------

Thanks in advance,

--
Catherine Letondal -- Pasteur Institute Computing Center