bioinformatics - R - heatmap - width of columns (layout?) -


i using heatpmap.2() on r represent gene expression in different samples. tried lot of things, unable control width of samples. here code basically:

heatmap.2( t(logm[1:6,1:500]),         colv=na,         col=my_palette,         colsep=3,        trace=c("none"),        density.info=c("none"),        adjcol = c(1,1), #more or less move text         cexrow = 0.1,         xlab="mices") 

i reduce size of columns (corresponding samples, i've got 6 samples, meaning 6 columns, can't post pictures illustration , sorry). have looked while on internet couldn't find looking for.

thank help, think can solved in 1 or 2 lines, when don't find...

best regards,

i recommend using pheatmap library. not provides sensible default parameters customizable well.

edata <- structure(list(controll = c(1.88652404567248, 7.56216163122565,  5.14725899353288, 6.08609722473225, -0.299183966356617, 4.25027223369266,  5.45902343668683, 5.85281618559412, 2.93112975036833, 6.12522039745773 ), controll.1 = c(2.29406389045036, 6.97597451795928, 4.5147662930767,  6.09625239882511, 0.921990457532795, 4.17832412568404, 5.95377074638688,  5.37442992479651, 0.54939804990357, 6.72853709005767), pert. = c(1.79358946043894,  7.90872166216125, 5.1124575575158, 6.29352463374008, 0.891739809245287,  4.84160106842908, 5.07613585232771, 3.61007431367141, 2.44943490047975,  5.27177316582586), pert..1 = c(2.20978097040356, 7.57067518392199,  4.59252962972135, 5.91408661908659, -0.339030105179552, 4.25593889774791,  4.80784977136993, 3.46482298621816, 2.34957363521685, 4.47242819598903 )), .names = c("controll", "controll.1", "pert.", "pert..1"), row.names = c("acrv1",  "dusp1", "gab1", "kif1c", "lass1", "mitd1", "nr2c2ap", "plekhg2",  "tekt3", "zdhhc20"), class = "data.frame")   library(pheatmap) pheatmap(edata) 

full width

pheatmap(edata, cellwidth=25) 

width 25


Comments

Popular posts from this blog

android - Pass an Serializable object in AIDL -

How to provide Authorization & Authentication using Asp.net, C#? -

How to use Authorization & Authentication in Asp.net, C#? -