bdgdiff.Rd
Differential peak detection based on paired four bedgraph files. Note: All regions on the same chromosome in the bedGraph file should be continuous so only bedGraph files from MACS3 are accpetable.
MACS pileup bedGraph for condition 1. Incompatible with callpeak –SPMR output. REQUIRED
MACS pileup bedGraph for condition 2. Incompatible with callpeak –SPMR output. REQUIRED
MACS control lambda bedGraph for condition 1. Incompatible with callpeak –SPMR output. REQUIRED
MACS control lambda bedGraph for condition 2. Incompatible with callpeak –SPMR output. REQUIRED
log10LR cutoff. Regions with signals lower than cutoff will not be considerred as enriched regions. DEFAULT: 3 (likelihood ratio=1000)
Minimum length of differential region. Try bigger value to remove small regions. DEFAULT: 200", default = 200
Maximum gap to merge nearby differential regions. Consider a wider gap for broad marks. Maximum gap should be smaller than minimum length (-g). DEFAULT: 100
Sequencing depth (# of non-redundant reads in million) for condition 1. It will be used together with –d2. See description for –d2 below for how to assign them. Default: 1
Sequencing depth (# of non-redundant reads in million) for condition 2. It will be used together with –d1. DEPTH1 and DEPTH2 will be used to calculate scaling factor for each sample, to down-scale larger sample to the level of smaller one. For example, while comparing 10 million condition 1 and 20 million condition 2, use –d1 10 –d2 20, then pileup value in bedGraph for condition 2 will be divided by 2. Default: 1
The output directory.
Output file prefix. Actual files will be named as PREFIX_cond1.bed, PREFIX_cond2.bed and PREFIX_common.bed. Mutually exclusive with -o/–ofile.
Output filenames. Must give three arguments in order: 1. file for unique regions in condition 1; 2. file for unique regions in condition 2; 3. file for common regions in both conditions. Note: mutually exclusive with –o-prefix.
Whether to capture logs.
Set verbose level of runtime message. 0: only show critical message, 1: show additional warning message, 2: show process information, 3: show debug messages. DEFAULT:2
macsList
object.
eh <- ExperimentHub::ExperimentHub()
CHIP <- eh[["EH4558"]]
#> see ?MACSdata and browseVignettes('MACSdata') for documentation
#> loading from cache
CTRL <- eh[["EH4563"]]
#> see ?MACSdata and browseVignettes('MACSdata') for documentation
#> loading from cache
c1 <- callpeak(CHIP, CTRL, gsize = 5.2e7, cutoff_analysis = TRUE,
outdir = tempdir(), name = "callpeak_narrow0", store_bdg = TRUE)
#>
c2 <- callpeak(CHIP, CTRL, gsize = 1e7, nomodel = TRUE, extsize = 250,
outdir = tempdir(), name = "callpeak_narrow_revert", store_bdg = TRUE)
#>
t1bdg <- grep("treat_pileup", c1$outputs, value = TRUE)
c1bdg <- grep("control_lambda", c1$outputs, value = TRUE)
t2bdg <- grep("treat_pileup", c2$outputs, value = TRUE)
c2bdg <- grep("control_lambda", c2$outputs, value = TRUE)
bdgdiff(t1bdg, t2bdg, c1bdg, c2bdg,
outdir = tempdir(), oprefix = "bdgdiff")
#>
#> macsList class
#> $outputs:
#> /tmp/RtmpkYWDbh/bdgdiff_c3.0_common.bed
#> /tmp/RtmpkYWDbh/bdgdiff_c3.0_cond1.bed
#> /tmp/RtmpkYWDbh/bdgdiff_c3.0_cond2.bed
#> $arguments: t1bdg, t2bdg, c1bdg, c2bdg, outdir, oprefix
#> $log:
#>