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

Diff of /FigKernelPackages/FIG.pm

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

revision 1.407, Sat Dec 10 18:08:17 2005 UTC revision 1.408, Sat Dec 10 23:05:58 2005 UTC
# Line 9423  Line 9423 
9423  }  }
9424    
9425    
9426    =head3 family_by_function
9427    
9428    Get a list of families that have a partial match to a provided function.
9429    
9430    E.g. my @families=$fig->family_by_function("histidine")
9431    
9432    will return histidine kinase, histidine phosphatase, etc etc etc
9433    
9434    =cut
9435    
9436    sub family_by_function {
9437     my ($self, $func)=@_;
9438     return () unless ($func);
9439     my($relational_db_response);
9440     my $rdbH = $self->db_handle;
9441    
9442     if ($rdbH->table_exists('localfam_function') &&
9443         ($relational_db_response = $rdbH->SQL("SELECT DISTINCT family from localfam_function where function like '\%$func\%'")) &&
9444         (@$relational_db_response >= 1))
9445     {
9446         return map { $_->[0] } @$relational_db_response;
9447     }
9448     return ();
9449    }
9450    
9451    
9452  ################################# Abstract Set Routines  ####################################  ################################# Abstract Set Routines  ####################################
9453    
9454  =head2 Abstract Set Routines  =head2 Abstract Set Routines

Legend:
Removed from v.1.407  
changed lines
  Added in v.1.408

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3