Learn R Programming

AllelicImbalance (version 1.6.2)

regionSummary: regionSummary

Description

Gives a summary of AI-consistency for a transcript

Usage

regionSummary(x, ...)
"regionSummary"(x, region, strand = "*", ...)

Arguments

x
ASEset object
...
arguments to forward to internal functions
region
GenomicRanges object to summmarize over
strand
can be "+", "-" or "*"

Details

From a given set of e.g. transcripts exon ranges the function will return a summary for the sum of all exons. Phase information is required.

Examples

Run this code
data(ASEset)
a <- ASEset
# Add phase
set.seed(1)
p1 <- matrix(sample(c(1,0),replace=TRUE, size=nrow(a)*ncol(a)),nrow=nrow(a), ncol(a))
p2 <- matrix(sample(c(1,0),replace=TRUE, size=nrow(a)*ncol(a)),nrow=nrow(a), ncol(a))
p <- matrix(paste(p1,sample(c("|","|","/"), size=nrow(a)*ncol(a), replace=TRUE), p2, sep=""),
	nrow=nrow(a), ncol(a))

phase(a) <- p

#add alternative allele information
mcols(a)[["alt"]] <- inferAltAllele(a)

# in this example every snp is on its own exon
txGR <- granges(a)
t <- regionSummary(a, txGR)

Run the code above in your browser using DataLab