rd.gcCorrect: readDepth: GC-content correction

Description Usage Arguments Details Value See Also Examples

View source: R/rd.gccorrect.R

Description

takes a readDepth object containing read counts and uses loess correction to account for GC content bias. Updates the @chrs rd column and adds a "gc" column containing that bin's GC content percentage

Usage

1
  rd.gcCorrect(rdo, meth=FALSE, outlierPercentage=0.01)

Arguments

rdo

a readDepth object created with new("rdObject") and filled with read counts using the readDepth() command

meth

if this data consists of bisulfite reads and a methylation map is present in annotations/methMap, gc correction will be done while taking into account the bisulfite treatment that converts C -> U and methylated bases that were protected from this conversion

outlierPercentage

Removes the highest and lowest N This prevents overfitting near the extremes, which loess is susceptible to. Default value is 0.01

Details

Assumes that files containing gc content and unmappable regions are in place (see full readDepth documentation for proper directory structure).

Value

returns a rd object with the read depth values altered to reflect gc content composition-induced bias.

See Also

'readDepth'

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
  ##create a rdObject, set bin params
  #  x <- new("rdObject")

  ##fill the bins with reads
  #  x.reads <- readDepth(x)

  ##do gc correction on the read counts
  #  x.map <- rd.mapCorrect(x.reads)

  ##do gc correction on the read counts
  #  x.gcCorr = rd.gcCorrect(x.map)

chrisamiller/readDepth documentation built on June 16, 2021, 2:05 p.m.