tool.normalize.quality: Check normalization quality

Description Usage Arguments Value Author(s) See Also Examples

View source: R/cle.LS.R

Description

tool.normalize.quality checks transformation quality by using Kolmogorov-Smirnov Test. It seeks the best log transform parameter within the previously specified upper and lower limits, and applies the log transform with the best log parameter.

Usage

1

Arguments

g

normalization quality control will take place according to the normal distribution parameters defined by g, e.g. it can be normal distribution with 0-mean and std dev 1.

z

transformed data, i.e. either p-value or enrichment score

Value

res

statitics of Kolmogorov-Smirnov Test result obtained for z values

Author(s)

Ville-Petteri Makinen

See Also

tool.normalize

Examples

1
2
3
4
5
6
7
8
9
set.seed(1)
## let us assume we have a set of normalized scores: 
z <- abs(rnorm(10)) ## it should be positive and at least 10 length-vector
z <- z/median(z)
## Find the best log transform.
gamma <- optim(par=1.0, fn=tool.normalize.quality, gr=NULL, z,
lower=-9, upper=9, control=list(reltol=1e-3))
## After finding the best log transform, apply transform:
z <- log(exp(gamma$par)*z + 1.0)

Mergeomics documentation built on Nov. 8, 2020, 6:58 p.m.