Perform enrichment analysis for (TF) motif footprinting

# S4 method for DsATAC
getMotifFootprints(
  .object,
  motifNames,
  samples = getSamples(.object),
  motifFlank = 250L,
  type = ".genome",
  motifDb = "jaspar"
)

Arguments

.object

DsATAC object

motifNames

character vector of motif names

samples

sample identifiers

motifFlank

number of base pairs flanking the motif on each side

type

(PLACEHOLDER ARGUMENT: NOT IMPLEMENTED YET) character string specifying the region type or ".genome" (default) for genome-wide profiling

motifDb

either a character string (currently only "jaspar" and sets contained in chromVARmotifs ("homer", "encode", "cisbp") are supported) or an object containing PWMs that can be used by motifmatchr::matchMotifs (such as an PFMatrixList or PWMatrixList object) OR a list of GRanges objects specifying motif occurrences

Value

a list of footprinting results with one element for each motif. Each motif's results contain summary data frames with aggregated counts across all motif occurrences and a ggplot object for plotting footprints

Author

Fabian Mueller

Examples

if (FALSE) {
dsa <- ChrAccRex::loadExample("dsAtac_ia_example")
motifNames <- c("MA1419.1_IRF4", "MA0139.1_CTCF", "MA0037.3_GATA3")
# motifNames <- grep("(IRF4|CTCF|GATA3)$", names(prepareMotifmatchr("hg38", "jaspar")$motifs), value=TRUE, ignore.case=TRUE) # alternative by searching
samples <- c("TeffNaive_U_1001", "TeffNaive_U_1002", "TeffMem_U_1001", "TeffMem_U_1002")
fps <- getMotifFootprints(dsa, motifNames, samples)
fps[["MA1419.1_IRF4"]]$plot
}