diffAnalysis: Differential analysis.

Description Usage Arguments Details Value Author(s) Examples

View source: R/PAA.r

Description

Performs a univariate differential analysis.

Usage

1
2
3
diffAnalysis(input=NULL, label1=NULL, label2=NULL, class1=NULL, class2=NULL,
output.path=NULL, mMs.matrix1=NULL, mMs.matrix2=NULL, above=1500,
between=400, features=NULL, feature.names=NULL)

Arguments

input

EList$E- or EListRaw$E-matrix extended by row names comprising BRC-IDs of the corresponding features (mandatory; note: it is expected that this matrix is in original scale and not in log2 scale).

label1

vector of column names for group 1 (mandatory).

label2

vector of column names for group 2 (mandatory).

class1

label of group 1 (mandatory).

class2

label of group 2 (mandatory).

output.path

string indicating a path for saving the results (optionally).

mMs.matrix1

precomputed mMs reference matrix (see mMsMatrix()) for group 1 (mandatory).

mMs.matrix2

precomputed mMs reference matrix (see mMsMatrix()) for group 2 (mandatory).

above

mMs above parameter (integer). Default is "1500".

between

mMs between parameter (integer). Default is "400".

features

vector of row indices (optional).

feature.names

vector of corresponding feature names (additionally to features).

Details

This function takes an EList$E- or EListRaw$E-matrix (e.g., temp <- elist$E) extended by row names comprising BRC-IDs of the corresponding features. The BRC-IDs can be created via:
brc <- paste(elist$genes[,1], elist$genes[,3], elist.$genes[,2]).
The BRC-row names can be defined as follows: rownames(temp) <- brc. Furthermore, the corresponding column name vectors, group labels and mMs-parameters are needed to perform the univariate differential analysis. This analysis covers inter alia p-value computation, p-value adjustment (method: Benjamini & Hochberg, 1995), and fold change computation. Since the results table is usually large, a path for saving the results can be defined via output.path. Optionally, a vector of row indices (features) and additionally (not mandatory for subset analysis) a vector of corresponding feature names (feature.names) can be forwarded to perform the analysis for a feature subset.

Value

A matrix containing the analysis results is returned.

Author(s)

Michael Turewicz, michael.turewicz@rub.de

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
cwd <- system.file(package="PAA")
load(paste(cwd, "/extdata/Alzheimer.RData", sep=""))
elist <- elist[elist$genes$Block < 10,]
c1 <- paste(rep("AD",20), 1:20, sep="")
c2 <- paste(rep("NDC",20), 1:20, sep="")
mMs.matrix1 <- mMs.matrix2 <- mMsMatrix(x=20, y=20)
temp <- elist$E
rownames(temp) <- paste(elist$genes[,1], elist$genes[,3], elist$genes[,2])
diffAnalysis(input=temp, label1=c1, label2=c2, class1="AD", class2="NDC",
 mMs.matrix1=mMs.matrix1, mMs.matrix2=mMs.matrix2, above=1500,
 between=400)

PAA documentation built on Nov. 8, 2020, 8:30 p.m.