Bio::EnsEMBL::Analysis::RunnableDB Genscan
SummaryIncluded librariesPackage variablesSynopsisDescriptionGeneral documentationMethods
Toolbar
WebCvsRaw content
Summary
Package variables
No package variables defined.
Included modules
Bio::EnsEMBL::Analysis::Config::General
Bio::EnsEMBL::Analysis::Runnable::Genscan
Bio::EnsEMBL::Analysis::RunnableDB
Bio::EnsEMBL::Analysis::Tools::Logger qw ( logger_info )
Bio::EnsEMBL::Utils::Exception qw ( throw warning )
Inherit
Bio::EnsEMBL::Analysis::RunnableDB
Synopsis
  my $runnabledb = Bio::EnsEMBL::Analysis::RunnableDB::Genscan->
new(
-input_id => 'contig::AL805961.22.1.166258:1:166258:1',
-db => $db,
-analysis => $analysis,
);
$runnabledb->fetch_input;
$runnabledb->run;
$runnabledb->write_output;
Description
fetches sequence data from database an instantiates and runs the
genscan runnable
Methods
fetch_inputDescriptionCode
runnable_path
No description
Code
standard_argsDescriptionCode
write_outputDescriptionCode
Methods description
fetch_inputcode    nextTop
  Arg [1]   : Bio::EnsEMBL::Analysis::RunnableDB::Genscan
Function : fetch data out of database and create runnable
Returntype: 1
Exceptions: none
Example :
standard_argscodeprevnextTop
  Arg [1]   : Bio::EnsEMBL::Analysis::RunnableDB::Genscan
Function : to return a hash which contains the
standard constructor args for the genscan runnable
Returntype: hashref
Exceptions: none
Example :
write_outputcodeprevnextTop
  Arg [1]   : Bio::EnsEMBL::Analysis::RunnableDB::Genscan
Function : writes the prediction transcripts back to the database
after validation
Returntype: none
Exceptions:
Example :
Methods code
fetch_inputdescriptionprevnextTop
sub fetch_input {
  my ($self) = @_;
  my $slice = $self->fetch_sequence($self->input_id, $self->db, 
                                    $ANALYSIS_REPEAT_MASKING);
  $self->query($slice);
  my %args = %{$self->standard_args};
  my $runnable = $self->runnable_path->new
    (
     %args,
    );
  
  my $seq = $self->query->seq; 
  if ($seq =~ /[CATG]{3}/) {
     $self->input_is_void(0);
  } else {
     $self->input_is_void(1);
     warning("Need at least 3 nucleotides - maybe your sequence was fully repeatmasked ...");
  }
  
  $self->runnable($runnable);
  return 1;
}
runnable_pathdescriptionprevnextTop
sub runnable_path {
  my ($self);
  return "Bio::EnsEMBL::Analysis::Runnable::Genscan";
}
standard_argsdescriptionprevnextTop
sub standard_args {
  my ($self) = @_;
  my %parameters;
  if($self->parameters_hash){
    %parameters = %{$self->parameters_hash};
  }
  return {
          -query => $self->query,
          -program => $self->analysis->program_file,
          -analysis => $self->analysis,
          %parameters,
          -matrix => $self->analysis->db_file,
         };
}
1;
}
write_outputdescriptionprevnextTop
sub write_output {
  my ($self) = @_;
  my $adaptor = $self->db->get_PredictionTranscriptAdaptor;
  my @output = @{$self->output};
  my $ff = $self->feature_factory;
  foreach my $pt(@output){
    $pt->analysis($self->analysis);
    $pt->slice($self->query) if(!$pt->slice);
    $ff->validate_prediction_transcript($pt, 1);
    $adaptor->store($pt);
  }
}
General documentation
CONTACTTop
Post questions to the Ensembl development list: ensembl-dev@ebi.ac.uk