signal_at_summit: Signal around all bedfile midpoints

Description Usage Arguments Value Examples

Description

This function allows you to pull out the ChIP signal centered around summits or midpoints of bedfiles if start and stop values are more than one base apart. It takes as input wiggle data as a list of 16 chromosomes (output ofreadall_tab) and a bedfile determining the positions to extract. This function can also be used to get signal around centromeres (see second example below). Use with signal_average to calculate the mean for every position around all midpoints.
Written by Tovah Markowitz.

Usage

1
signal_at_summit(inputData, bedData, extension = 1000, onlyComplete = TRUE)

Arguments

inputData

A list of 16 chr wiggle data (output of readall_tab). No default.

bedData

A data frame of bed data to extract signal around. No default.

extension

Number indicating the number of bases around the summit or midpoints. Value will be added both upstream and downstream. Default is 1000 bp.

onlyComplete

Many wiggle files are missing data at random positions across the genome. Boolean indicates if you want to only keep regions where every base is included within the wiggle file. Default is TRUE.

Value

An R (dplyr) data frame with four columms: chromosome name, position (relative to midpoint), signal, and bed line number within its individual chromosome

Examples

1
2
3
4
5
6
7
## Not run: 
signal_at_summit(WT, red1_summit_bed)

# For signal around centromeres:
signal_at_summit(WT, S288Ccen, extension = 2e4, onlyComplete = FALSE)

## End(Not run)

luisvalesilva/hwglabr documentation built on May 21, 2019, 8:56 a.m.