# ppa.normalize: Normalize input data for use with the PPA In isa2: The Iterative Signature Algorithm

## Description

Normalize the two input matrices and store them in a form that can be used effectively to perform the Ping-Pong Algorithm

## Usage

 ```1 2``` ```## S4 method for signature 'list' ppa.normalize(data, ...) ```

## Arguments

 `data` A list of two numeric matrices, with matching number of columns. They might contain `Na` and/or `NaN` values. `...` Additional arguments, see details below.

## Details

This function can be called as

 ```1 2``` ``` isa.normalize(data, prenormalize = FALSE) ```

where the arguments are:

data

A list of two numeric matrices, with matching number of columns. They might contain `Na` and/or `NaN` values.

prenormalize

Logical scalar, see details below.

It was observed that the PPA works best if the input matrices are scaled to have mean zero and standard deviation one.

A PPA step consist of four matrix-multiplications and this requires four different matrices, each of the two input matrices scaled row-wise and column-wise.

If the `prenormalized` argument is set to `TRUE`, then row-wise scaling is calculated on the column-wise scaled matrices and not on the raw input.

## Value

A list of four matrices, the first two corresponds to the first input matrix, the second two to the second matrix.

## Author(s)

Gabor Csardi [email protected]

## References

Kutalik Z, Bergmann S, Beckmann, J: A modular approach for integrative analysis of large-scale gene-expression and drug-response data Nat Biotechnol 2008 May; 26(5) 531-9.

See `ppa` for an easy way of running the PPA

## 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``` ```## In-silico data set.seed(1) insili <- ppa.in.silico() nm <- ppa.normalize(insili[1:2]) ## Check it max(abs(rowSums(nm[[1]]))) max(abs(rowSums(nm[[2]]))) max(abs(rowSums(nm[[3]]))) max(abs(rowSums(nm[[4]]))) max(abs(rowSums(nm[[1]]))) max(abs(rowSums(nm[[2]]))) max(abs(rowSums(nm[[3]]))) max(abs(rowSums(nm[[4]]))) ## Plot them if (interactive()) { layout(rbind(1:3,4:6)) image(insili[[1]], main="Original data 1") image(t(nm[[1]]), main="Row normalized 1") image(nm[[2]], main="Column normalized 1") image(insili[[2]], main="Original data 2") image(t(nm[[3]]), main="Row normalized 2") image(nm[[4]], main="Column normalized 2") } ```

isa2 documentation built on May 29, 2017, 6:44 p.m.