Skip to content
Snippets Groups Projects
Commit ea945dc6 authored by Alessandro Vullo's avatar Alessandro Vullo
Browse files

[ENSCORESW-1117]. Get the list of genome components for a polyploid genome.

parent ce272c1e
No related merge requests found
......@@ -1186,4 +1186,30 @@ sub is_polyploid {
return $polyploid > 2;
}
=head2 get_genome_components
Arg : None
Example : $components = $genome->get_genome_components();
Description: Returns the list of (diploid) components, for a
polyploid genome
Returntype : Arrayref
Exceptions : none
Caller : general
Status : Stable
=cut
sub get_genome_components {
my $self = shift;
my $sql_helper = $self->dbc->sql_helper;
my $sql =
"SELECT DISTINCT value
FROM seq_region_attrib JOIN attrib_type
USING (attrib_type_id) WHERE attrib_type.code='genome_component'";
return $sql_helper->execute_simple(-SQL => $sql);
}
1;
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment