[Bio] / FigKernelPackages / Subsystem.pm Repository:
ViewVC logotype

Diff of /FigKernelPackages/Subsystem.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.77, Thu Dec 8 19:50:50 2005 UTC revision 1.78, Fri Dec 30 11:52:01 2005 UTC
# Line 2943  Line 2943 
2943      $self->load_version();      $self->load_version();
2944  }  }
2945    
2946    
2947    =head3 functional_role_instances
2948    
2949    C<< my @role_instances = $sub->functional_role_instances($role); >>
2950    
2951    Returns the set of genes for a functional role that belong to
2952    genomes with functional variants (> 0).
2953    
2954    =cut
2955    
2956    sub functional_role_instances {
2957    
2958        my ($self, $role) = @_;
2959        my $i =0;
2960    
2961        my @instances;
2962    
2963        foreach my $cell (@{$self->get_col($self->get_role_index($role))}) {
2964    
2965            if ((scalar @$cell > 0) && ($self->get_variant_code($i) > 0)) {
2966                foreach (@$cell) {
2967                    push @instances, $_;
2968                }
2969            }
2970            $i++;
2971        }
2972    
2973    
2974        return @instances if wantarray;
2975        return \@instances;
2976    
2977    }
2978    
2979    
2980    
2981    
2982  =head3 get_dir_from_name  =head3 get_dir_from_name
2983    
2984  C<< my $dirName = Subsystem::get_dir_from_name($name); >>  C<< my $dirName = Subsystem::get_dir_from_name($name); >>

Legend:
Removed from v.1.77  
changed lines
  Added in v.1.78

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3