View source: R/annotation_biomart.R
load_biomart_orthologs | R Documentation |
Biomart's function getLDS is incredibly powerful, but it makes me think very polite people are going to start knocking on my door, and it fails weirdly pretty much always. This function attempts to alleviate some of that frustration.
load_biomart_orthologs(
gene_ids = NULL,
first_species = "hsapiens",
second_species = "mmusculus",
host = NULL,
trymart = "ENSEMBL_MART_ENSEMBL",
archive = TRUE,
default_hosts = c("useast.ensembl.org", "uswest.ensembl.org", "www.ensembl.org",
"asia.ensembl.org"),
year = NULL,
month = NULL,
trydataset = NULL,
attributes = "ensembl_gene_id"
)
gene_ids |
List of gene IDs to translate. |
first_species |
Linnean species name for one species. |
second_species |
Linnean species name for the second species. |
host |
Ensembl server to query. |
trymart |
Assumed mart name to use. |
archive |
Use an archive server? |
default_hosts |
Set of default hosts to query. |
year |
When using an archive server, use this year (otherwise it will choose last year). |
month |
When using an archive server, use this month (otherwise, this month). |
trydataset |
Choose a dataset to query. |
attributes |
Key to query |
Tested in test_40ann_biomart.R As with my other biomart functions, this one grew out of frustrations when attempting to work with the incredibly unforgiving biomart service. It does not attempt to guarantee a useful biomart connection, but will hopefully point out potentially correct marts and attributes to use for a successful query. I can say with confidence that it works well between mice and humans.
list of 4 elements: The first is the set of all ids, as getLDS seems to always send them all; the second is the subset corresponding to the actual ids of interest, and the 3rd/4th are other, optional ids from other datasets.
[biomaRt::getLDS()]
mouse_yeast_orthologs <- load_biomart_orthologs(gene_ids = NULL, first_species = "mmusculus",
second_species = "scerevisiae")
head(mouse_yeast_orthologs$all_linked_genes)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.