[Bioc-devel] Heatplus Heatmap Fails for Hidden Dendrogram and Labels
Hi Dario, thanks for the feedback. Let's take this one by one:
plot(regHeatmap(expressionMatrix)) shows a heatmap. When I add an extra parameter plot(regHeatmap(expressionMatrix), list(status = "hidden")) I get the error Error in plot.new() : outer margins too large (figure region too small) In addition: Warning message: In pad1.rm.cm(widths, cm.widths, len = num.cols) : NAs introduced by coercion It's strange that the figure region is too small, because it's supposed to be plotting less than for the first example, which worked.
The plot.new() error is typical for a too small output device - increase the window size or the width/height of the file you are plotting to, and it should go away. This may happen even if the plot causing the error is technically "smaller" than one which does not - for each plot, the device is split into multiple parts (using layout()), and the error will occur if just one of the parts (say for the legend) is too small.
Also, the documentation and the vignette are inconsistent about the values that can be used. In the vignette is the example has status="hide" but the function's documentation writes "hidden means re-rorder".
Yeah, that's a bit of sloppy programming on my side: any value that is not "yes" or "no" will be interpreted as "hidden", so both status="hide" and status="hidden" will work the same way.
Providing row and column labels also fails. str(expressionMatrix) num [1:45, 1:18] 18.56 46.65 4.52 52.12 0.26 ... plot(regHeatmap(expressionMatrix, labels = list(labels=list(Row = 1:45, Col = 1:18), side = list(Row = 4, Col = 1)))) Error in mmar[x$labels$Row$side] = x$labels$Row$nrow : invalid subscript type 'list'
You have to switch the "labels" and Row/Col in the command: ## Example setting labels require(Heatplus) example(regHeatmap) ## generate some data map1 = regHeatmap(mat, labels=list(Row=list(labels=1:20), Col=list(labels=1:5))) plot(map1) HTH, alexander
Alexander Ploner Medical Epidemiology & Biostatistics Karolinsksa Institutet http://ki.se/meb