[Bioperl-l] problem setting mismatch penalty in StandAloneBlast.pm
without setting quiet()
Jason Stajich
jason at cgt.duhs.duke.edu
Mon Jul 19 17:34:50 EDT 2004
Oops quiet and q are being stored in the same slot.
Try adding this in your code (before a factory is instantiated).
sub Bio::Tools::Run::StandAloneBlast::quiet {
my $self = shift;
return $self->{'_quiet'} = shift if @_;
return $self->{'_quiet'};
}
I've added this change in CVS and a test in StandAloneBlast.t
-jason
On Mon, 19 Jul 2004, Scott Markel wrote:
> I'm using BioPerl 1.4 on a Windows XP box. When I set the
> mismatch penalty for blastn, I get both the "-q" command line
> option, which I want, and errors getting redirected to /dev/null,
> which I don't want. The problem seems to be the following
> line in Bio::Tools::Run::StandAloneBlast's _setparams():
>
> if ($self->quiet()) { $param_string .= ' 2>/dev/null';}
>
> A constructor call
>
> $factory = Bio::Tools::Run::StandAloneBlast->new(@params);
>
> followed by either $factory->q(-3) or $factory->quiet(-3)
> both result in "-q -3" being added to the command line *and*
> " 2>/dev/null" being appended to the command line.
>
> I've tried calling $factory->verbose() with verbosity values
> of -1, 0, 1, and 2, but this didn't get rid of the /dev/null
> redirection.
>
> How do I set the mismatch value without tripping $self->quiet()
> in StandAloneBlast.pm?
>
> Scott
>
>
--
Jason Stajich
Duke University
jason at cgt.mc.duke.edu
More information about the Bioperl-l
mailing list