BioPerl

 view release on metacpan or  search on metacpan

Bio/Assembly/Scaffold.pm  view on Meta::CPAN

              Synchronizes the assembly registry for sequences in
              contigs and contig actual aligned sequences content. You
              probably want to run this after you remove/add a
              sequence from/to a contig in the assembly.

    Returns : 1 for success
    Args    : none 

=cut

sub update_seq_list {
    my $self = shift;
    
    $self->{'_seqs'} = {};

    # Put sequences in contigs in list of sequences belonging to the scaffold
    foreach my $contig ($self->all_contigs) {
        my $contigID = $contig->id();
        foreach my $seqID ($contig->get_seq_ids) {
            if (exists $self->{'_seqs'}{$seqID} &&
                not($self->{'_seqs'}{$seqID} eq $contig) ) {

Bio/DB/GFF/Adaptor/dbi/pg.pm  view on Meta::CPAN


  my $count = 0;
  while (my @row = $sth->fetchrow_array) {
    $callback->(@row);
    $count++;
  }
  $sth->finish;
  return $count;
}

sub update_sequences {
  my $self = shift;
  my $dbh  = $self->features_db;
 
  $dbh->do("SELECT setval('public.fdata_fid_seq', max(fid)+1) FROM fdata");
  $dbh->do("SELECT setval('public.fattribute_fattribute_id_seq', max(fattribute_id)+1) FROM fattribute");
  $dbh->do("SELECT setval('public.fgroup_gid_seq', max(gid)+1) FROM fgroup");
  $dbh->do("SELECT setval('public.ftype_ftypeid_seq', max(ftypeid)+1) FROM ftype");

  1;
}

Bio/DB/GFF/Adaptor/dbi/pg_fts.pm  view on Meta::CPAN

=head2 update_TSearch2

 Title   : update_TSearch2
 Function: Updates TSearch2 columns
 Usage   : $db->update_TSearch2
 Status  : public

=cut


sub update_TSearch2 {
  my $self = shift;

  my $dbh = $self->features_db;

  $self->warn('updating full text column; this may take a very long time...');
  $dbh->do("UPDATE fattribute_to_feature "
          ."SET idxFTI= to_tsvector('default', fattribute_value) "
          ."WHERE idxFTI IS NULL") 
       or $self->throw('updating fti column failed');
  $dbh->do("UPDATE fgroup "

Bio/DB/SeqFeature/NormalizedFeature.pm  view on Meta::CPAN

 Returns : true if successful
 Args    : none
 Status  : public

After changing any fields in the feature, call update() to write it to
the database. This is not needed for add_SeqFeature() as update() is
invoked automatically.

=cut

sub update {
  my $self = shift;
  my $store = $self->object_store or return;
  $store->store($self);
}

=head2 get_SeqFeatures

 Title   : get_SeqFeature
 Usage   : @subfeatures = $feature->get_SeqFeatures([@types])
 Function: return subfeatures of this feature

Bio/DB/SeqFeature/Store/berkeleydb.pm  view on Meta::CPAN

  return if $delete; # we don't know how to do this

  my $fh = $self->notes_db;
  my @notes = $obj->get_tag_values('Note') if $obj->has_tag('Note');


  print $fh $_,"\t",pack("u*",$id) or $self->throw("An error occurred while updating note index: $!")
    foreach @notes;
}

sub update_or_delete {
  my $self = shift;
  my ($delete,$db,$key,$id) = @_;
  if ($delete) {
    tied(%$db)->del_dup($key,$id);
  } else {
    $db->{$key} = $id;
  }
}

# these methods return pointers to....

Bio/PhyloNetwork/Factory.pm  view on Meta::CPAN

    $parent=Bio::PhyloNetwork::TreeFactory->new(-leaves=>\@leaves);
  }
  $self->{parent}=$parent;
  my $oldnet=$parent->next_network();
  $self->{oldnet}=$oldnet;
  $self->update();
  $self->{found}=[];
  bless($self,$pkg);
}

sub update {
  my ($self)=@_;

  my @candidates=$self->{oldnet}->edges();
  $self->{candidates}=\@candidates;
  $self->{numcandidates}=(scalar @candidates);
  $self->{index1}=-$self->{recurse};
  $self->{index2}=0;
}

=head2 next_network

Bio/PhyloNetwork/FactoryX.pm  view on Meta::CPAN

    $self->{subfactories}=[$parent];
  }
  $self->{parent}=$parent;
  $self->update();
  $self->{found}=[];
  $self->{thrown}=0;
  $self->{hybnow}=0;
  bless($self,$pkg);
}

sub update {
  my ($self)=@_;

  if (defined $self->{oldnet}) {
    my @candidates=$self->{oldnet}->edges();
    $self->{candidates}=\@candidates;
    $self->{numcandidates}=(scalar @candidates);
    $self->{index1}=0;
    $self->{index2}=0;
  } else {
    $self->{candidates}=[];

Bio/Species.pm  view on Meta::CPAN

sub division {shift->taxon->division(@_)}

sub common_names {shift->taxon->common_names(@_)}
sub common_name {shift->taxon->common_names(@_)}

sub genetic_code {shift->taxon->genetic_code(@_)}
sub mitochondrial_genetic_code {shift->taxon->mitochondrial_genetic_code(@_)}

sub create_date { shift->taxon->create_date(@_)}
sub pub_date { shift->taxon->pub_date(@_)}
sub update_date { shift->taxon->update_date(@_)}

sub db_handle { shift->taxon->db_handle(@_)}

sub parent_id { shift->taxon->parent_id(@_)}
sub parent_taxon_id { shift->taxon->parent_id(@_)}

sub version { shift->taxon->version(@_)}
sub authority { shift->taxon->authority(@_)}
sub namespace { shift->taxon->namespace(@_)}

Bio/Taxon.pm  view on Meta::CPAN

=head2 update_date

 Title   : update_date
 Usage   : $taxon->update_date($newval)
 Function: Get/Set Date this node was updated (in the database)
 Returns : value of update_date (a scalar)
 Args    : on set, new value (a scalar or undef, optional)

=cut

sub update_date {
    my $self = shift;
    return $self->{'update_date'} = shift if @_;
    return $self->{'update_date'};
}


=head2 pub_date

 Title   : pub_date
 Usage   : $taxon->pub_date($newval)

examples/tk/gsequence.pl  view on Meta::CPAN

    my ( $widget, $file_selection ) = @_;
    push @filename, $file_selection->get_filename();

    $widget->parent->parent->parent->destroy();

    my $in = Bio::SeqIO->new(-file => $filename[-1] , '-format' => 'swiss');

    &new_seq_page($in->next_seq());
}

sub update_seq_data
{    
    $main_label[$current]->set_text($seq[$current]->id) if (defined($seq[$current]));
    $main_label[$current]->set_text("<New>") if (!defined($seq[$current]));

    $seq_edit[$current]->freeze();
    $seq_edit[$current]->delete_text(0,-1);
    $seq_edit[$current]->insert(undef,undef,undef,$seq[$current]->seq()) if (defined($seq[$current]));
    $seq_edit[$current]->thaw();

    &update_comment_window();

 view all matches for this distribution
 view release on metacpan -  search on metacpan

( run in 0.808 second using v1.00-cache-2.02-grep-82fe00e-cpan-4673cadbf75 )