This function adds information about which peaks contain input regions to a given ArchRProject. For each peak, a binary value is stored indicating whether each region is observed within the peak region.

addPeakAnnotations(
  ArchRProj = NULL,
  regions = NULL,
  name = "Region",
  force = FALSE,
  logFile = createLogFile("addPeakAnnotations")
)

Arguments

ArchRProj

An ArchRProject object.

regions

A named list of GRanges that are to be overlapped with the peakSet in the ArchRProject.

name

The name of peakAnnotation object to be stored as in ArchRProject.

force

A boolean value indicating whether to force the peakAnnotation object indicated by name to be overwritten if it already exists in the given ArchRProject.

logFile

The path to a file to be used for logging ArchR output.

Examples


# Get Test ArchR Project
proj <- getTestProject()

# Get Motif Positions Can Be Any Interval GRanges List
positions <- getPositions(proj)

# Add Peak Annotations
proj <- addPeakAnnotations(proj, regions = positions)