% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/runMACS.R
\name{runMACSForAll}
\alias{runMACSForAll}
\title{Call Peaks Using MACS2 For All Clusters}
\usage{
runMACSForAll(obj, output.prefix, path.to.snaptools, path.to.macs, gsize,
  tmp.folder, num.cores = 1, min.cells = 100, buffer.size = 500,
  macs.options = "--nomodel --shift 37 --ext 73 --qval 1e-2 -B --SPMR --call-summits",
  keep.minimal = TRUE)
}
\arguments{
\item{obj}{A snap object.}

\item{output.prefix}{Prefix of output file which will be used to generate output file names.}

\item{path.to.snaptools}{Path to snaptools excutable file.}

\item{path.to.macs}{Path to macs2 excutable file.}

\item{gsize}{effective genome size. 'hs' for human, 'mm' for mouse, 'ce' for C. elegans, 'dm' for fruitfly (default: None)}

\item{tmp.folder}{Directory to store temporary files generated by runMACSForAll.}

\item{num.cores}{number of cpus to use [1].}

\item{min.cells}{min number of cells to perform peak calling [100]. Clusters with cells less 
than num.cells will be excluded.}

\item{buffer.size}{Buffer size for incrementally increasing internal array size to store reads alignment information. In
most cases, you don't have to change this parameter. However, if there are very high coverage dataset that each barcode has
more than 10000 fragments, it's recommended to specify a smaller buffer size in order to decrease memory usage (but it will take longer time to read snap files) [1000].}

\item{macs.options}{String indicate options you would like passed to macs2. strongly do not recommand to change unless you know what you are doing. the default is '--nomodel --shift 37 --ext 73 --qval 1e-2 -B --SPMR --call-summits'.}

\item{keep.minimal}{Keep minimal version of output [TRUE].}
}
\value{
Return a GRanges object that contains the non-overlapping combined peaks
}
\description{
Identify peaks for all clusters. Fragments belonging to each subset or cluster of cells 
are extracted and used to identify peaks using MACS2. This function requires
"MACS2" and "snaptools" preinstalled and excutable.
}
