Description Usage Arguments Details Value Author(s) Examples
Overlaps query gap-sites (from BAM alignment data) with annotated splice junctions (from reference genome annotation).
1 | overlapJuncs(qry, junc)
|
qry |
|
junc |
|
The function finds optimal overlapping hits for alignment gap-sites in
annotated splice-sites.
A gap-site is the combination of two genomic regions (= exons) which enclose
an intermediary (= intron).
The function identifies junction records which overlap with the given
gap-site (=hits) and select a junction with an optimal fit.
The goodness of fit is measured by the distance of the inner
gap boundaries (= the splice sites) between query and junction record.
A junction with minimal sum of upstream and downstrem distances is selected.
The selection of the best hit depends on the order a version of the junction
table wich is sorted by lstart
and rend
.)
The function returns a data.frame
qid |
|
refid |
|
ldiff |
|
rdiff |
|
nref |
|
sod |
|
first_refid |
|
last_refid |
|
nadv |
|
strand |
Strand value derived from annotation. |
gene_id |
Gene id from |
transcript_id |
Transcript id from |
gene_name |
Gene name from |
Wolfgang Kaisers
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 | ##-------------------------------------##
## A) Example query data
##-------------------------------------##
## 1 2 3 4 5 6 7 ##
qry <- data.frame(id = 1:7, seqid = "1",
lstart = c(10100L, 11800L, 12220L, 12220L, 12220L, 32000L, 40000L),
lend = c(10100L, 12000L, 12225L, 12227L, 12227L, 32100L, 40100L),
rstart = c(10200L, 12200L, 12057L, 12613L, 12650L, 32200L, 40200L),
rend = c(10300L, 12250L, 12179L, 12620L, 12700L, 32300L, 40300L))
## 1 2 3 4 5 6 7 ##
##-------------------------------------##
## B) Example reference data
##-------------------------------------##
# B.1) Ensembl genome:
ensfile <- system.file("extdata", "hs.ensembl.62.small.RData", package="refGenome")
ens <- loadGenome(ensfile)
gp <- getGenePositions(ens)
# B.2) Ensembl junctions:
junc <- getSpliceTable(ens)
##-------------------------------------##
## C) Do overlap
##-------------------------------------##
res <- overlapJuncs(qry, junc)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.