extractByGeneName: extractByGeneName: Extract subset for sites which lie in...

Description Usage Arguments Details Value Author(s) Examples

Description

The function takes a 'cRanges' object (or derived) and searches inside of given 'refGenome' object for gene names. From identified gene-name matches genomic target regions can be defined for wich in turn the contained sites are extracted.

Usage

1
extractByGeneName(object,geneNames,src,...)

Arguments

object

gapSites or cRanges (or derived). Object inside which the data is searched for.

geneNames

Character. Vector of gene names for which data is to be extracted.

src

refGenome. Contains gene annotation (for conversion of gene-name to genomic coordinates).

...

(currently unused)

Details

The function internally calls 'extractByGeneName' on 'refGenome'. This function also prints out non matching gene names. On the result, the function calls 'getGenePositions' from which the genomic regions can be extracted. For each gene, data is extracted via 'extractRange' and the resulting objects are then concatenated.

Value

Same type as object

Author(s)

Wolfgang Kaisers

Examples

 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) Read gapSites from BAM
bam<-system.file("extdata","rna_fem.bam",package="spliceSites")
reader<-bamReader(bam,idx=TRUE)
ga<-alignGapList(reader)
bamClose(reader)
# B) Load DNAStringSet
dnafile<-system.file("extdata","dna_small.RData",package="spliceSites")
load(dnafile)
# C) load refGenome
ucf<-system.file("extdata","uc_small.RData",package="spliceSites")
uc<-loadGenome(ucf)
# D) For cRanges
lj<-lJunc(ga,featlen=6,gaplen=3,strand='+')
ljw<-extractByGeneName(lj,geneNames="WASH7P",src=uc)
# E) For cdRanges
ljc<-lCodons(lj,frame=2)
ljcd<-dnaRanges(ljc,dna_small)
ljcdw<-extractByGeneName(ljcd,geneNames="WASH7P",src=uc)
# F) For caRanges
ljca<-translate(ljcd)
ljcaw<-extractByGeneName(ljca,geneNames="WASH7P",src=uc)
# G) For gapSites
lrj<-lrJunc(ga,lfeatlen=6,rfeatlen=6,strand='+')
lrjw<-extractByGeneName(lrj,geneNames="WASH7P",src=uc)

wokai/spliceSites documentation built on May 4, 2019, 9:46 a.m.