[Bioperl-l] :DB::SeqFeature oddities
Cook, Malcolm
MEC at stowers.org
Sun Mar 15 20:28:29 UTC 2009
Marco,
It looks to me like in your first call, get_features_by_location is returning many features, the first 10 of which happen to be gene features that have subordinate mRNA features which are collected in the map.
In the 2nd call, you are now trying to collect the 'gene' features subordinate to the first 10 features. But these 10 features ARE themselves gene features and so don't have subordinate gene features.
Depending on what you are trying to do, you might want instead:
map{print $_->name, "\n"} ($db->get_features_by_location(-seq_id =>'4', -types => [qw(mRNA)]))[1..10];
and
map{print $_->name, "\n"} ($db->get_features_by_location(-seq_id =>'4', -types => [qw(gene)]))[1..10];
--Malcolm
________________________________________
From: bioperl-l-bounces at lists.open-bio.org [bioperl-l-bounces at lists.open-bio.org] On Behalf Of Blanchette, Marco [MAB at stowers.org]
Sent: Sunday, March 15, 2009 3:01 PM
To: BioPerl mailing list
Subject: [Bioperl-l] Bio::DB::SeqFeature oddities
One more Bio::DB::SeqFeature oddities...
I am trying to fetch the genes underlying a given location in the genome.
The MySql database was populated whit the most recent Drosophila gff3
annotation using bp_seqfeature_load.pl using the fast mode (-f). Somehow,
there is something I don¹t get with the features Ogene¹.
For example, I can get 10 mRNAs from the fourth chromosome using:
use Bio::DB::SeqFeature::Store;
our $db = Bio::DB::SeqFeature::Store->new( -adaptor => 'DBI::mysql',
-dsn => 'dbi:mysql:dmel_5_15');
map{print $_->name, "\n"} (map{$_->get_SeqFeatures('mRNA')}
$db->get_features_by_location(-seq_id =>
'4'))[1..10];
Results:
CG11231-RA
CG33797-RA
CG11077-RA
JYalpha-RB
RpS3A-RA
RpS3A-RB
RpS3A-RD
CG32006-RA
CG31997-RA
CG2219-RA
However, if I try to fetch the Ogene¹ features, I get an empty array as in
map{print $_->name, "\n"} (map{$_->get_SeqFeatures('gene')}
$db->get_features_by_location(-seq_id =>
'4'))[1..10];
>>NOTHING
And I get the same whether I use OGene¹ or OGENE¹.
Any idea what¹s going on here?
Thanks
--
Marco Blanchette, Ph.D.
Assistant Investigator
Stowers Institute for Medical Research
1000 East 50th St.
Kansas City, MO 64110
Tel: 816-926-4071
Cell: 816-726-8419
Fax: 816-926-2018
_______________________________________________
Bioperl-l mailing list
Bioperl-l at lists.open-bio.org
http://lists.open-bio.org/mailman/listinfo/bioperl-l
More information about the Bioperl-l
mailing list