sc15-normalize: Normalization

Description Usage Arguments Details Value Author(s) References See Also Examples

Description

This function performs normalization for sample loading after quantification. It is typically invoked as part of the process of creating summary information from an RPPASet object.

Usage

1
2
3
4
5
6
## S4 method for signature 'MatrixLike'
normalize(object,
          method=getRegisteredNormalizationMethodKeys(),
          calc.medians=TRUE,
          sweep.cols=calc.medians,
          ...)

Arguments

object

data frame or matrix to be normalized

method

character string specifying name of method of sample loading normalization (see section ‘Details’ below)

calc.medians

logical scalar. If TRUE, calculate row and column median values from the data to be normalized.

sweep.cols

logical scalar. If TRUE, subtract column medians from data values prior to invoking the normalization method.

...

extra arguments for normalization routines

Details

By default, column medians are subtracted from the input data values; these adjusted data values are then passed to the requested normalization routine for further processing.

The method argument may be augmented with user-provided normalization methods. Package-provided values are:

medpolish Tukey's median polish normalization
median sample median normalization
house housekeeping normalization
vs variable slope normalization

Specifying “median” as the method argument causes the row median to be subtracted from each sample. Specifying “house” causes the median of one or more housekeeping antibodies to be used. The names of the antibodies to be used must be supplied as a named argument to this method. Specifying “vs” causes the sample median to be used along with a multiplicative gamma (see reference below).

Value

Returns normalized concentrations as matrix appropriately annotated.

Author(s)

P. Roebuck proebuck@mdanderson.org, E. Shannon Neeley sneeley@stat.byu.edu

References

Neeley ES, Kornblau SM, Coombes KR, Baggerly KA.
Variable slope normalization of reverse phase protein arrays
Bioinformatics (2009) 25(11): 1384-1389.
https://academic.oup.com/bioinformatics/article/25/11/1384/331482/Variable-slope-normalization-of-reverse-phase

See Also

RPPASet

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
antibodies <- c("FOO", "BAR", "PLUGH", "WALDO")
concs <- matrix(rnorm(1024),
                ncol=length(antibodies),
                dimnames=list(samples=NULL, antibodies=antibodies))

## Normalize using sample median
normconcs <- normalize(concs, method="median")
str(normconcs)

## Normalize using housekeeping antibodies
normconcs <- normalize(concs, method="house", antibodies=c("FOO", "PLUGH"))
str(normconcs)

## Normalize using variable slope
normconcs <- normalize(concs, method="vs")
str(normconcs)

## Normalize using Tukey's median polish (previous default method)
normconcs <- normalize(concs, method="medpolish", calc.medians=FALSE)
str(normconcs)

## Normalize using user-provided method (in this case, robust sample mean)
normalize.robustmean <- function(concs, trim=0, na.rm=FALSE) {
    stopifnot(is.matrix(concs) || is.data.frame(concs))
    stopifnot(is.numeric(trim))
    stopifnot(is.logical(na.rm))

    rowMean <- apply(concs, 1, mean, trim=trim, na.rm=na.rm)
    normconcs <- sweep(concs, 1, rowMean, FUN="-")

    ## Store method-specific info in "normalization" attribute
    attr(normconcs, "normalization") <- list(rowMean=rowMean)

    normconcs
}

registerNormalizationMethod("rmean", normalize.robustmean)
normconcs <- normalize(concs, method="rmean", trim=0.1, na.rm=TRUE)
str(normconcs)

SuperCurve documentation built on May 2, 2019, 6:14 p.m.