This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Can't convert dog ensembl IDs into gene names

I usually use biomaRt to convert gene ids to symbols. However, this time the ensembl IDs I have (dog) do not match the ensembl ids of biomart dataset "clfamiliaris_gene_ensembl".

I also tried to use the ensembl web portal, the dog dataset is called ROS_Cfam_1.0 there. Looks like my genes do not match the genes from their dataset. My genes look like this:

"ENSCAFG00000045440" "ENSCAFG00000000001" "ENSCAFG00000000002" "ENSCAFG00000041462" "ENSCAFG00000000005"

. Here is my biomaRt code:

ensembl <- useMart("ensembl")
ensembl <- useDataset("clfamiliaris_gene_ensembl",mart=ensembl)
gene_id <- getBM(attributes = c('ensembl_gene_id', 'external_gene_name'),
                 values = rownames(mydata),
                 filters = c('ensembl_gene_id'), mart = ensembl)
gene_id
[1] ensembl_gene_id    external_gene_name
<0 rows> (or 0-length row.names)

it doesn't find my values. Should I use a different dataset for dogs?

rna-seq dog ensembl biomart

Looks like these gene ID's are from a different dog breed, namely boxer. See if clfamiliarisboxer_gene_ensembl works?

3 answers

You are right, Genomax. These IDs are from the Boxer dog genome assembly: https://www.ensembl.org/Canis_lupus_familiaris/Info/Strains?db=core

However, BioMart is not available for dog breeds (as well as other species and strains): https://www.ensembl.info/2021/01/20/important-changes-of-data-availability-in-ensembl-gene-trees-and-biomart/

However, you can use the POST lookup/id REST API endpoint to retrieve the gene symbol for a list of gene IDs from any species: http://rest.ensembl.org/documentation/info/lookup_post

I've posted on Gist this script to download a csv table made by Ensembl gene id -> symbol using any of the supported species in Ensembl. It's written in Python3

Can you clarify what do you mean by "supported species"? Also include a usage statement for the script in the gist to help novice users.

Thank you! Please don't remove the script on Gist!

$ python query_ensembl.py --list organism
...
canis_lupus_familiaris
...
$ python query_ensembl.py --organism canis_lupus_familiaris

It will make a table file.

You can achive this conversion with biobtreeR simply use all these dog species names along with human which takes few minutes to build the local database

bbBuildCustomDB(rawArgs = "-s homo_sapiens,canis_lupus_dingo,canis_lupus_familiaris,canis_lupus_familiarisbasenji,canis_lupus_familiarisgreatdane build")

And map your ensembl IDs to human with a query(you can check the doc for examples) and then you will reach the gene symbols.

Log in to answer this question.