Re: [R] comparing heatmaps

From: Alex Gutteridge <alexg_at_ruggedtextile.com>
Date: Tue, 29 Mar 2011 11:40:36 +0100

 On Mon, 28 Mar 2011 19:58:40 -0700, Peter Langfelder wrote:
> On Mon, Mar 28, 2011 at 6:36 PM, Benton, Paul
> <hpaul.benton08_at_imperial.ac.uk> wrote:
>> Benno,
>>
>> That helps but it only makes the color bar symmetrical. I want to be
>> able to compare 2 different heatmaps so that 0.7 (for example) is
>> always the same tone of green and not shifted slightly. Is this
>> possible?
>>
>> Paul
>
>>From what I can see it is not possible with heatmap.2. If you are
> looking for a function that can create a heatmap with a color legend,
> you can try function image.plot in the package fields, or the
> function
> labeledHeatmap in the package WGCNA. Neither of them has the
> histogram-enhanced color legend, but labeledHeatmap definitely takes
> an argument zlim which you can set to say c(-1, 1) to obtain a
> consistent color scale, and the last time I used image.plot (which
> was
> quite some time ago), that function also took that argument.
>
> See examples listed in help(labeledHeatmap) for a few examples of
> what
> it can do.
>
> Peter
>
> ______________________________________________
> R-help_at_r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide
> http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.

 Perhaps I misunderstand, but the color scale can be explicitly defined  in heatmap.2 using the breaks argument.

-- 
 Alex Gutteridge

______________________________________________
R-help_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Received on Tue 29 Mar 2011 - 10:46:44 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Tue 29 Mar 2011 - 11:00:25 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive