Hi all, I have a distance matrix (symmetric) which looks somewhat like this (only a small portion shown)
ENSG00000101413 ENSG00000176884 ENSG00000185532 ENSG00000106829 ENSG00000101413 1.000 1.000 1.000 1.000 ENSG00000176884 0.328 0.258 0.260 0.390 ENSG00000185532 1.000 1.000 1.000 1.000 ENSG00000106829 0.684 0.443 0.531 0.701 These distances are custom measures that I need to cluster. Since it's a symmetric matrix I only need to consider one half triangle of the matrix. So I do something like this :- newmat <- ensembl_copygosimmat newmat[upper.tri(ensembl_copygosimmat)] <- NA Then I wanted to visualize how the lower triangle looked using pheatmap which does hierarchical clustering itself. library(pheatmap) pheatmap(newmat) But since there are NA values in the matrix (in the upper half) it always throws an error. I was wondering what would be the ideal way to visualize as well as cluster such a matrix. Regards Saad [[alternative HTML version deleted]] ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see 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.