motifProfile: motifProfile for the GRanges objects

Description Usage Arguments Value Author(s) Examples

View source: R/motifProfile.R

Description

An function to plot the frequency or fraction of the interested motif around the center of input peaks.

Usage

1
2
3
4
5
6
7
8
motifProfile(
    object,
    motif = NA,
    genome = NA,
    fraction = TRUE,
    title = "Motif Profile",
    flanking = 10
)

Arguments

object

A GRanges object which should contains all the peaks that you want to check

motif

A character string which use the IUPAC nucleotide code, e.g. DRACH, TTAGGG.

genome

The name of the full genome sequences package in the Bioconductor, e.g. "BSgenome.Mmusculus.UCSC.mm10". You should install the package before running this function.

fraction

A logical vector (TRUE or FALSE) that the result should be presented in fraction or number.

title

The main title for the output meta gene profile plot.

flanking

The size of the flanking windows that you would like to check. Flanking=5 will give you the result of the 10+1nt windows around the center of peaks.

Value

A list object, the list 1 contains the information of the frequency of specified motif around the center of peaks. The list 2 includes the plot of motifProfile.

Author(s)

You Zhou, Kathi Zarnack

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
## Load the test data and get the path to the test gff3 file
testpath <- system.file("extdata", package = "cliProfiler")
test <- readRDS(file.path(testpath, "test.rds"))
test_gff3 <- file.path(testpath, "annotation_test.gff3")

## Please make sure that the correct BSgenome package have installed before
## running motifProfile. For example,library("BSgenome.Mmusculus.UCSC.mm10")
## would be required for the mouse data.

output <- motifProfile(test,
    motif = "DRACH",
    genome = "BSgenome.Mmusculus.UCSC.mm10",
    flanking = 20
)

Codezy99/cliProfiler documentation built on Dec. 17, 2021, 2:59 p.m.