loadAnnotation | R Documentation |
This function loads an annotation element from a local
sitadela annotation database. If the annotation is not
found and the organism is supported, the annotation is
fetched and created on the fly but not imported in the
local database. Use addAnnotation
for this
purpose (build/update/add annotations).
loadAnnotation(genome, refdb,
type = c("gene", "transcript", "utr",
"transutr", "transexon", "exon"),
version="auto", wtv = FALSE,
db = getDbPath(), summarized = FALSE,
asdf = FALSE, rc = NULL)
genome |
a sitadela supported organism or a custom organism name imported by the user. |
refdb |
a sitadela supported annotation source or a custom name imported by the user. |
type |
the transcriptional unit annotation level
to load. It can be one of |
version |
the version of the annotation to use. See Details. |
wtv |
load annotations with versioned genes and transcripts when/where available. |
db |
same as the |
summarized |
if |
asdf |
return the result as a |
rc |
same as the |
Regarding org
, it can be, for human genomes
"hg18"
, "hg19"
or "hg38"
, for mouse
genomes "mm9"
, "mm10"
, for rat genomes
"rn5"
or "rn6"
, for drosophila genome
"dm3"
or "dm6"
, for zebrafish genome
"danrer7"
, "danrer10"
or "danrer11"
,
for chimpanzee genome "pantro4"
, "pantro5"
,
for pig genome "susscr3"
, "susscr11"
, for
Arabidopsis thaliana genome "tair10"
and for
Equus caballus genome "equcab2"
and "equcab3"
.
Finally, it can be "USER_NAMED_ORG"
with a custom
organism which has been imported to the annotation database
by the user using a GTF/GFF file. For example
org="mm10_p1"
.
Regarding type
, it defines the level of
transcriptional unit (gene, transcript, 3' UTR, exon)
coordinates to be loaded or fetched if not present. The
following types are supported:
"gene"
: canonical gene coordinates are
retrieved from the chosen database.
"transcript"
: all transcript
coordinates are retrieved from the chosen database.
"utr"
: all 3' UTR coordinates are
retrieved from the chosen database, grouped per
gene.
"transutr"
: all 3' UTR coordinates are
retrieved from the chosen database, grouped per \
transcript.
"transexon"
: all exon coordinates are
retrieved from the chosen database, grouped per
transcript.
"exon"
: all exon coordinates are
retrieved from the chosen database.
Regarding version
, this is an integer denoting the
version of the annotation to use from the local annotation
database or fetch on the fly. For Ensembl, it corresponds
to Ensembl releases, while for UCSC/RefSeq, it is the
date of creation (locally).
The function returns a GenomicRanges
object or a
data.frame
with the requested annotation.
Panagiotis Moulos
db <- file.path(system.file(package="sitadela"),
"annotation.sqlite")
if (file.exists(db))
gr <- loadAnnotation(genome="hg19",refdb="ensembl",
type="gene",db=db)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.