Hi, I would like to run a blast search for a fasta file containing many (100+) seqences. I wrote a test script and ran it using a test query file (contains only one sequence; fh= diffexp1). If my code is right, the script should output the query name and the hit name in terminal. Although the script doesn't throw out any errors when I run it from command line, I don't get any output. I've let the program run for hours and still nothing. I'm using BioPerl-1.6.1 and Perl-5.16.1 on Ubuntu 12.04 LTS. Any help would be appreciated.
Here's the script:
#!/home/mack/bin/perl
use Bio::Tools::Run::RemoteBlast;
use Bio::SearchIO;
my $prog='blastn';
my $db='nr';
my $e_val='1e-10';
my $Input='diffexp1';
my @params = ('-prog' => $prog, '-data' => $db, '-expect' =>
$e_val, '-readmethod' => 'SearchIO');
my $factory = Bio::Tools::Run::RemoteBlast->new(@params);
$r =$factory->submit_blast($Input);
while (@rids =$factory->each_rid ){
for $rid (@rids ){
$rc =$factory->retrieve_blast($rid);
}
}
my $report = Bio::SearchIO->new(-file =>$rc, -format =>'blast');
while (my $result = $report->next_result) {
my $i=0;
while (my $hit = $result->next_hit){
print STDOUT $result->query_name, "\t";
print STDOUT $hit->name, "\t";
}
}
if (i==0) {print STDOUT "No Hits \n"; }