Dear Bioconductor Community,
i tried to create a heatmap via the heatmap.2 function of the gplots R package, to represent a subset of 554 DEG genes acquired from limma regarding an affymetrix microarray dataset.
My code is the following:
library(gplots)
color.map <- function(Disease) { if (Disease=="Normal") "#FF0000" else "#0000FF" }
patientcolors <- unlist(lapply(eset.3$Disease, color.map)) # define a color bar to distinguish cancer from control samples
heatmap.2(exprs(eset.3), col=greenred(75), scale="none", ColSideColors=patientcolors,key=TRUE, symkey=FALSE, density.info="none", trace="none", cexRow=0.8, cexCol=0.8, margins=c(8,8))
However, the resulting image seems weird( i have the link in the dropbox), as it is totally red without any variation in the expression range, and also the color key values in the top left have values ranging from -15, which doesnt seem logic !!
Just to pinpoint, the range of the intensity values in a histogram plots of the selected DE genes, is from ~5 to 15(log-intensity values)
Maybe it is possible to change the limits of the color key range to depict the true range or it is irrelevant ?
Any suggestion or help would be crusial !!
The link to the dropbox image file[https://www.dropbox.com/s/6ojjqnuhrdlpb0t/heatmap.problem.jpeg?dl=0]
And also Here's my sessionInfo:
sessionInfo()
R version 3.2.0 (2015-04-16)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 8 x64 (build 9200)
locale:
[1] LC_COLLATE=Greek_Greece.1253 LC_CTYPE=Greek_Greece.1253
[3] LC_MONETARY=Greek_Greece.1253 LC_NUMERIC=C
[5] LC_TIME=Greek_Greece.1253
attached base packages:
[1] parallel stats graphics grDevices utils datasets methods
[8] base
other attached packages:
[1] RColorBrewer_1.1-2 gplots_2.17.0 limma_3.24.15
[4] Biobase_2.28.0 BiocGenerics_0.14.0
loaded via a namespace (and not attached):
[1] tools_3.2.0 KernSmooth_2.23-15 splines_3.2.0 gdata_2.17.0
[5] caTools_1.17.1 bitops_1.0-6 gtools_3.5.0