| overlapPermTest {regioneR} | R Documentation |
Performs a permutation test to see if there is an association in overlap between a region set A and a region set B creating random regions through the genome.
overlapPermTest (A, B, alternative="auto", ...)
A |
a region set in any of the accepted formats by |
B |
a region set in any of the accepted formats by |
alternative |
the alternative hypothesis must be one of |
... |
further arguments to be passed to or from methods. |
A list of class permTestResults containing the following components:
pval the p-value of the test.
ntimes the number of permutations.
alternative a character string describing the alternative hypotesis.
observed the value of the statistic for the original data set.
permuted the values of the statistic for each permuted data set.
zscore the value of the standard score. (observed-mean(permuted))/sd(permuted)
overlapGraphicalSummary, overlapRegions, toDataframe, toGRanges, permTest
genome <- filterChromosomes(getGenome("hg19"), keep.chr="chr1")
A <- createRandomRegions(nregions=20, length.mean=10000000, length.sd=20000, genome=genome, non.overlapping=FALSE)
B <- c(A, createRandomRegions(nregions=10, length.mean=10000, length.sd=20000, genome=genome, non.overlapping=FALSE))
pt <- overlapPermTest(A=A, B=B, ntimes=10, genome=genome, non.overlapping=FALSE, verbose=TRUE)
summary(pt)
plot(pt)
plot(pt, plotType="Tailed")