Learn R Programming

charm (version 2.18.0)

normalizeBetweenSamples: Between-sample normalization

Description

Between-sample normalization for two-color DNA methylation microarray data.

Usage

normalizeBetweenSamples (dat, copy=TRUE, m="allQuantiles", untreated="none", enriched="none", controlProbes=NULL, controlIndex=NULL, excludeIndex=NULL, verbose=FALSE)

Arguments

dat
a TilingFeatureSet object
copy
Only relevant when using disk-backed objects. If TRUE a copy will be made leaving the original object (dat) unchanged. The input object will not be preserved if copy=FALSE
m
normalization method for log-ratios. "allQuantiles" for full quantile normalization, or "none"
untreated
normalization method for the untreated channel. "complete", "allQuantiles" or "none"
enriched
normalization method for the untreated channel. "sqn", "allQuantiles" or "none"

controlProbes
character string of the label assigned to non-CpG control probes in the annotation file (i.e. the container column of the .ndf file).
controlIndex
a vector of non-CpG control probe indices
excludeIndex
a vector indicating which pm probes to ignore when creating normalization target distributions. Can be a vector of probe indices or a boolean vector of length(pmindex(dat)).
verbose
boolean: Verbose output?

Value

a TilingFeatureSet

Details

This function is used by methp performs between-sample normalization. It is normally not used directly by the user.

See Also

methp

Examples

Run this code
	if (require(charmData) & require(BSgenome.Hsapiens.UCSC.hg18)) {
		phenodataDir <- system.file("extdata", package="charmData")
		pd <- read.delim(file.path(phenodataDir, "phenodata.txt"))
		pd <- subset(pd, sampleID=="441_liver")
		dataDir <- system.file("data", package="charmData")
		setwd(dataDir)
		rawData <- readCharm(files=pd$filename, sampleKey=pd)
		# Correct spatial artifacts
		dat <- spatialAdjust(rawData)
		# Remove background signal
		dat <- bgAdjust(dat)
		# Find non-CpG control probes
		ctrlIdx <- getControlIndex(rawData, subject=Hsapiens)
		# Within-sample normalization
		dat <- normalizeWithinSamples(dat, controlIndex=ctrlIdx)
		# Within-sample normalization
		dat <- normalizeBetweenSamples(dat)
	}

Run the code above in your browser using DataLab