[R] When scale is applied in heatmap

David Carlson dcarlson at tamu.edu
Mon Aug 5 17:50:05 CEST 2013


You might try posting to R-devel to get a response. Looking at
the source for heatmap, it does seem to be a "feature" rather
than a bug since the cluster analysis is performed well before
any scaling is applied. Would heatmap(scale(X)) accomplish
what you want?


-------------------------------------
David L Carlson
Associate Professor of Anthropology
Texas A&M University
College Station, TX 77840-4352


-----Original Message-----
From: r-help-bounces at r-project.org
[mailto:r-help-bounces at r-project.org] On Behalf Of Witold E
Wolski
Sent: Monday, August 5, 2013 3:17 AM
To: r-help at r-project.org
Subject: [R] When scale is applied in heatmap

When clustering I would do something like

plot(hclust(dist(scale(X))))


In case of  heatmap and heatmap.2 it seems to me that for the
dendrograms
plot(hclust(dist(X)))
is done
while for the heatmap
image(scale(X)) is done.

I would say this is a bug however, because this is consistent
among
the heatmap functions, can anyone enlighten me why this is so?





-- 
Witold Eryk Wolski

______________________________________________
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.



More information about the R-help mailing list