[ensembl-dev] Question regarding the fetching if gene info using external names

Duarte Molha Duarte.Molha at ogt.co.uk
Wed Nov 21 15:49:49 GMT 2012


Dear developers

I have a question regarding the use of the methods "fetch_all_by_display_label" and "fetch_all_by_external_name"

Consider this snippet of code:

my $query_gene = "MT-TG";
my @fetched_genes = @{$gene_adaptor->fetch_all_by_display_label($query_gene)};
unless (@fetched_genes){
@fetched_genes =  @{ $gene_adaptor->fetch_all_by_external_name($query_gene) };
}
foreach my $a (@fetched_genes) {
                                [do something]...
}

Although, MT-TG is the approved HGNC symbol for this gene ( http://www.genenames.org/data/hgnc_data.php?hgnc_id=7486 ), I am unable to retrieve data for it from the ensemble database.
In ensembl this gene is called J01415.16 with the ENSGID: ENSG00000210164 (http://www.ensembl.org/Homo_sapiens/Gene/Summary?g=ENSG00000210164;r=MT:9991-10058;t=ENST00000387429 )
Can you tell me what I am doing wrong and how to change my code so I can retrieve is particular gene of interest?
Best regards

Duarte Molha

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.ensembl.org/pipermail/dev_ensembl.org/attachments/20121121/1174a3a9/attachment.html>


More information about the Dev mailing list