Summary | Included libraries | Package variables | Synopsis | Description | General documentation | Methods |
WebCvs | Raw content |
use Bio::EnsEMBL::Funcgen::Utils::Encode qw(get_encode_regions);
my $encode_regions = &get_encode_regions($dnadb, $assembly_version);
get_encode_regions | Description | Code |
get_encode_regions | code | next | Top |
Arg [1] : Bio::EnsEMBL::DBSQL::DBAdaptor |
get_encode_regions | description | prev | next | Top |
my $db = shift; throw("Need to pass a valid Bio::EnsEMBL::DBSQL::DBAdaptor") if (! ($db && $db->isa("Bio::EnsEMBL::DBSQL::DBAdaptor"))); my $sa = $db->get_SliceAdaptor(); my $tls = $sa->fetch_all('toplevel'); #map { print Dumper $_->name } @$tls;}
my $mfa = $db->get_MiscFeatureAdaptor(); my @encode_regions; map { push @encode_regions, @{$mfa->fetch_all_by_Slice_and_set_code($_, 'encode')}; } @$tls; return\@ encode_regions; #my %encode_regions;
#map { $encode_regions{$_->display_id} = sprintf
# ("%s:%s:%s:%d:%d:%d",
# $_->slice->coord_system_name,
# $_->slice->coord_system()->version(),
# $_->slice->seq_region_name,
# $_->start, $_->end, $_->strand);
# } @encode_regions;
#
#return \%encode_regions;
} 1;
AUTHOR | Top |
CONTACT | Top |