createOffset: Create Offsets for Peak Calling

Description Usage Arguments Details Value Author(s) References Examples

View source: R/createOffset.R

Description

Given a mixNBHMMDataSet, this function creates offsets for peak calling. The current implementation can output three different sets of offsets: the sample-specific log sum of read counts (type="sum"), smoothed MA trend (type="loess"), or median ratio (type="ratio").

Usage

1
createOffset(object, type, span = 1)

Arguments

object

a mixNBHMMDataSet

type

either 'sum' (sample-specific log sum of read counts), 'loess' (smoothed MA trend), or 'ratio' (median ratio).

span

proportion of data to be used in the smoothing (see details)

Details

If type='sum', the offsets are calculated as the log column-wise sum of read counts + 1. If type='loess', the offsets will be the smoothed curve fitted on the MA plot that compares each sample's read counts + 1 over the geometric mean across all samples. The smoothing approach has been similarly implemented in csaw. If type='ratio', the offsets will be the median ratio of the sample's read counts + 1 over the geometric mean across all samples.

Value

The mixNBHMMDataSet with an 'offset' assay filled in.

Author(s)

Pedro L. Baldoni, [email protected]

References

https://github.com/plbaldoni/mixNBHMM Nucleic Acids Research 44, e45 (2015).

Examples

1
2
data(ENCODE)
ENCODE <- createOffset(object = ENCODE,type = 'loess',span = 1)

plbaldoni/mixNBHMM documentation built on Dec. 24, 2019, 1:31 p.m.