SWAP.PlotKTSP.GenePairClassesBoxplot {switchBox} | R Documentation |
Plots two genes or features, each as a pair of boxplots seperated to two classes or phenotypes.
SWAP.PlotKTSP.GenePairClassesBoxplot(genes, inputMat, Groups, classes=NULL, points=FALSE, ordering="byGene", colors=c(), point_colors=c(), point_directions=FALSE, ...)
genes |
is a vector of length two providing the pair
(from the rownames of |
inputMat |
is a matrix of data with rows being the features (such as gene names, if the matrix if gene expression data) and columns being the samples. |
Groups |
is a factor or a vector providing the phenotype class
each sample belongs to. It should correspond to the order of samples
given by the columns of |
classes |
is a vetor of length 2 providing the two phenotype or
class labels of |
points |
is a logical value indicating whether to overlay the boxplot with points for individual samples or not. |
ordering |
can be either 'byGene' or 'byClass' respectively indicating whether to plot two adjacent boxplots for each class/phenotype or two adjacent boxplots for each gene/features. |
colors |
is a character vector indicating the color to be used for each class or gene boxplots. |
point_colors |
is a character vector indicating the color to be used for the points. |
point_directions |
is a logical indicating whether to color the points by whether the first gene is less than the second gene. |
... |
any further arguments are supplied to the |
Produces a pair of boxplots indicating the distribution of the measured values for the pair of features/genes.
Bahman Afsari bahman.afsari@gmail.com, Luigi Marchionni marchion@jhu.edu, Wikum Dinalankara wdinala1@jhmi.edu
See switchBox for the references.
### Load gene expression data data(trainingData) ### train 1-TSP classifier = SWAP.Train.1TSP(matTraining, trainingGroup) ### plot top pair SWAP.PlotKTSP.GenePairClassesBoxplot(classifier$TSPs, matTraining, trainingGroup, levels(trainingGroup), points=TRUE, ordering="byGene")