generateBackground: Generate median background read depth

Description Usage Arguments Value Examples

Description

Normalizes a set of columns representing read counts from different samples by their mean. Then calculates a statistic across the rows of normalized counts.

Usage

1
  generateBackground(sample.names, rdata, fn=median)

Arguments

sample.names

A vector of column names in rdata to be used as background samples

rdata

A RangedData object containing the read counts

fn

The statistic to be applied across the rows of normalized counts. Defaults to median, but the standard deviation can also be calculated in this way.

Value

The value of fn applied across the rows of normalized read counts.

Examples

1
2
3
4
5
6
  data(exomecounts)
  sample.names <- grep("HG.+",colnames(exomecounts),value=TRUE)
  exomecounts[["bg"]] <- generateBackground(sample.names, exomecounts,
median) 
  exomecounts[["bg.sd"]] <- generateBackground(sample.names,
exomecounts, sd) 


Search within the exomeCopy package
Search all R packages, documentation and source code

Questions? Problems? Suggestions? or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.