DispersionMeasureFactory {xegaSelectGene}R Documentation

Configure dispersion measure.

Description

DispersionMeasureFactory returns a function for the dispersion measure as specified by a label. If an invalid label is specified, the configuration fails.

Usage

DispersionMeasureFactory(method = "var")

Arguments

method

A dispersion measure.

  • "var": Variance (Default).

  • "std": Standard deviation.

  • "mad": Median absolute deviation (mad(vec, constant=1)).

  • "cv": Coefficient of variation".

  • "range": Range.

  • "iqr": Inter quartile range (approximated by the lower and upper hinge of fivenum).

If an invalid label is specified, the configuration fails.

Value

A function which computes the dispersion measure from the vector of population statistics produced by xegaObservePopulation of package xegaPopulation.

See Also

Other Configuration: EvalGeneFactory(), ScalingFactory(), SelectGeneFactory()

Examples

require(stats)
fit<-sample(30, 20, replace=TRUE)
populationStats<-c(mean(fit), fivenum(fit), var(fit), mad(fit, constant=1))
dm<-DispersionMeasureFactory("var")
dm(populationStats)
dm<-DispersionMeasureFactory("range")
dm(populationStats)

[Package xegaSelectGene version 1.0.0.0 Index]