Getting BlastXML using RemoteBlast

According to NCBI – BlastXML (and ASN.1) is the only guaranteed always parseable report format that is provided by their web CGI script. Here is some code to specify how the data should be requested (and perhaps this will become the default).


my $remote_blastxml = Bio::Tools::Run::RemoteBlast->new
      ('-verbose'    => $v,
       '-prog'       => $prog,
       '-data'       => $db,
       '-readmethod' => 'xml',  # this tells the parser to use  blastxml
                                                  # format for parsing
       '-expect'     => $e_val,
       );
 # this  tells NCBI to send you XML back
$remote_blastxml->retrieve_parameter('FORMAT_TYPE', 'XML');

See also wiki page and NCBI email about Remote BLAST.

-jason


Categories