Make heatmaps of the co-expression (Spearman correlation) between pairs of selected genes in a dataset.
plotHeatmap(geneNames, emat, groupVec = NULL)
geneNames | Vector indicating the subset of genes in the rownames of
|
---|---|
emat | Matrix of expression values, where each row corresponds to a
gene and each column corresponds to a sample. The elements of |
groupVec | Optional vector indicating the group to which group each sample belongs. If not provided, the function assumes all samples belong to the same group. |
A ggplot
object, which can be saved using ggplot2::ggsave()
.
Heatmap colors will be directly comparable to any heatmaps created by this
function or by plotRefHeatmap()
.
if (FALSE) { library('deltaccd') library('doParallel') library('doRNG') registerDoParallel(cores = 2) set.seed(35813) refCor = getRefCor() ccdResult = calcCCD(refCor, GSE19188$emat, GSE19188$groupVec, dopar = TRUE) deltaCcdResult = calcDeltaCCD( refCor, GSE19188$emat, GSE19188$groupVec, 'non-tumor', dopar = TRUE) pRef = plotRefHeatmap(refCor) pTest = plotHeatmap(rownames(refCor), GSE19188$emat, GSE19188$groupVec) }