1
$\begingroup$

In the biomaRt package, there is a function getBM which among a few things is useful for mapping between different gene representations. Currently, I'm using it as follows, to map Ensembl transcript IDs to gene names and Ensembl gene IDs.

ensemble2gene <- getBM(attributes=c("ensembl_transcript_id", 
                                    "external_gene_name",
                                    "ensembl_gene_id"),
                       values = as.list(transcripts), 
                       mart = mart)

How is the following code different:

ensemble2gene <- getBM(attributes=c("ensembl_transcript_id", 
                                    "external_gene_name",
                                    "ensembl_gene_id"),
                       filters = "ensembl_transcript_id",
                       values = as.list(transcripts), 
                       mart = mart)

It's unclear to me from the description of the filters argument here. But just based on results, I get less results when I run the second one.

$\endgroup$
0

1 Answer 1

0
$\begingroup$

Hi An Ignorant Wanderer,

Filters allow you to narrow down the dataset to query a specific subset of features within your dataset. A description and tutorial of the filtering steps within BioMart can be found here: https://www.ensembl.org/info/data/biomart/how_to_use_biomart.html

If you remove filters, you will query the full dataset (all human genes, in the example above). However, this is not recommended for BioMart as large, genome-wide queries will overload the BioMart servers. For queries of this size, we suggest using the Ensembl REST API or FTP site.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.