This function uses the biomaRt package.
Usage
getTx2gene(
organism = "mmusculus",
version = NULL,
outputDir = "data",
checkArgsOnly = FALSE
)
Arguments
- organism
String used to pass
paste0(organism, "_gene_ensembl")
as thedataset
argument tobiomaRt::useEnsembl()
. To see available datasets, domart = biomaRt::useEnsembl("genes"); biomaRt::listDatasets(mart)
.- version
Passed to
biomaRt::useEnsembl()
.NULL
indicates the latest version. To see available versions, dobiomaRt::listEnsemblArchives()
.- outputDir
Directory in which to save the result, a file named "tx2gene.csv.gz". If
NULL
, no file is saved.- checkArgsOnly
Logical indicating whether to only check function arguments. Used for testing.
Value
If checkArgsOnly
is FALSE
, a data.table based on the result from
biomaRt::getBM()
, with an attribute "version". Otherwise 0
.