motifEnrichment | R Documentation |
function to find enrichment motif between two motifscan result
motifEnrichment(InputMotif, ControlMotif, ...)
## S4 method for signature
## 'RangedSummarizedExperiment,RangedSummarizedExperiment'
motifEnrichment(InputMotif, ControlMotif)
InputMotif |
should be generated by
|
ControlMotif |
should be generated by
|
return Motif Enrichment data.frame of InputMotif by ControlMotif
motifEnrichment(
InputMotif = RangedSummarizedExperiment,
ControlMotif = RangedSummarizedExperiment
)
: RangedSummarizedExperiment/RangedSummarizedExperiment
example_motifs <- getJasparMotifs(species = "Homo sapiens",
collection = "CORE")
# Make a set of input regions
Input <- GenomicRanges::GRanges(seqnames = c("chr1","chr2","chr2"),
ranges = IRanges::IRanges(start = c(76585873,42772928,
100183786),
width = 500))
# Make a set of control regions
Control <- GenomicRanges::GRanges(seqnames = c("chr1","chr3","chr5"),
ranges = IRanges::IRanges(start = c(453123,6524593,
100184233),
width = 500))
# Scan motif for example motifs
motif_ix_input <- motifScan(example_motifs, Input, genome = "BSgenome.Hsapiens.UCSC.hg19")
motif_ix_control <- motifScan(example_motifs, Control, genome = "BSgenome.Hsapiens.UCSC.hg19")
# Find Enrichment motif of input by control
Enrichment_result <- motifEnrichment(motif_ix_input, motif_ix_control)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.