Entering edit mode
Lourdes Peña Castillo
▴
140
@lourdes-pena-castillo-1305
Last seen 10.3 years ago
Hello,
I am trying to get a heatmap from gene expression data using a
different distance function rather than the default (dist with
euclidean distance).
Specifically, I was trying to use disscosangle available in the
hopach package setting distfun as follows:
>heatmap(t(probesExp), col = mypalette, distfun = disscosangle, labCol
= "", scale = "none");
but I get this error:
Error in if (n < 2) stop("must have n >= 2 objects to cluster") :
argument is of length zero
I checked whether disscosangle could be used at all using:
as.dist(disscosangle(probesExp))
and it works fine.
However, I could not find the right way to give it as a parameter to
heatmap. Somebody knows how to do this?
In addition, how can I add to the image of the heatmap a map between
the colors used and the values of the data? I mean how to have the
color palette in one side of the image with the corresponding value
each color represents.
Thanks!
Lourdes