[ensembl-dev] Gene xrefs and descriptions in a flat file?

Stefano Giorgetti sgiorgetti at ebi.ac.uk
Thu Oct 20 11:59:22 BST 2022


Hello Julie,

The REST API for Xrefs were conceived for mainly query EnsEMBL using 
non-EnsEMBL identifiers/accession numbers: thus, I am not sure they may 
be fit for your purpose.

Also, I am not sure I can understand your use case: a gene may come with 
many Xrefs. Please, see for instance
https://www.ensembl.org/Homo_sapiens/Gene/Matches?db=core;g=ENSG00000038219;r=4:13568738-13627725;t=ENST00000040738

Assuming - because of your Perl snippet - you have EnsEMBL gene stable 
IDs, you are happy with using REST API, and _you are interested in the 
"gene description" only_, I might suggest to look at the */lookup *end point

For instance, 
https://rest.ensembl.org/lookup/id/ENSG00000038219?content-type=application/json

If REST does not work for you, you may want to download the "gene" table 
dump to find the same information

https://ftp.ensembl.org/pub/release-108/mysql/homo_sapiens_core_108_38/gene.txt.gz

Hope it helps

Any further questions, please do not hesitate to reach out

Best wishes,

Stefano

On 14/10/2022 13:22, Julie Sullivan wrote:
> Is there a flat file I can download that contains gene xrefs and 
> descriptions?
>
> I see the end point in the REST API for xrefs but I don't see 
> descriptions.
>
> https://rest.ensembl.org/
>
> And I see the Perl API has these data so I can do this:
>
> $gene->stable_id."\t".$gene->description."\n";
>
> But the environment I'm running these scripts in doesn't allow for me 
> to install the mysql client, so I haven't be able to successfully run 
> that except on my laptop (where it times out).
>
> Any suggestions? Thank you!!
>
>
> _______________________________________________
> Dev mailing listDev at ensembl.org
> Posting guidelines and subscribe/unsubscribe info:https://lists.ensembl.org/mailman/listinfo/dev_ensembl.org
> Ensembl Blog:http://www.ensembl.info/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.ensembl.org/pipermail/dev_ensembl.org/attachments/20221020/71698327/attachment.html>


More information about the Dev mailing list