homogenizeData: Take two expression matrices and return homogenized versions...

View source: R/homogenize_data.R

homogenizeDataR Documentation

Take two expression matrices and return homogenized versions of the matrices.

Description

This function accepts two expression matrices, with gene ids as rownames() and sample ids as colnames(). It will deal with duplicate gene ids. subset and order the matrices correctly. and perform homogenize the data using whatever method is specified (by default Combat from the sva library).

Usage

homogenizeData(testExprMat, trainExprMat, batchCorrect = "eb",
  selection = -1, printOutput = TRUE)

Arguments

testExprMat

Gene expression matrix for samples on which we wish to predict a phenotype. Gene names as rows, samples names as columns.

batchCorrect

The type of batch correction to be used. Options are "eb" for Combat, "none", or "qn" for quantile normalization.

selection

parameter can be used to specify how duplicates are handled, by default value -1 means ask the user. 1 means summarize duplictes by their mean and 2 means to disguard all duplicate genes.

printOutput

Set to FALSE to supress output

trainingExprMat

Gene expression matrix for samples for which we the phenotype is already known.

Value

a list containing two entries $train and $test, which are the homogenized input matrices.


SiYangming/pRRophetic documentation built on July 13, 2022, 10:36 p.m.