Commit 467a594e authored by Magali Ruffier's avatar Magali Ruffier
Browse files

slices are ordered, better chance of finding the genes on the first slices

parent 0bffed27
......@@ -19,7 +19,11 @@ sub run {
my $sum = 0;
my $slices = Bio::EnsEMBL::Registry->get_adaptor($species, 'core', 'slice')->fetch_all('toplevel');
while (my $slice = shift @$slices) {
my @sorted_slices =
sort( { $a->coord_system()->rank() <=> $b->coord_system()->rank()
|| $b->seq_region_length() <=> $a->seq_region_length() } @$slices) ;
while (my $slice = shift @sorted_slices) {
foreach my $code (keys %attrib_codes) {
my $count = $self->get_feature_count($slice, $code, $attrib_codes{$code});
$self->store_attrib($slice, $count, $code);
......
Markdown is supported
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