ComplexHeatmap
ComplexHeatmap copied to clipboard
hclust size cannot be NA nor exceed 65536
my dataset is 77422*207 without NA, it showed error as:
Error in hclust(get_dist(submat, distance), method = method) : size cannot be NA nor exceed 65536 Calls: draw ... make_row_cluster -> .local -> make_cluster -> hclust Execution halted
it means can not handle more than 65536 rows?
Thank you!
It is the limit of hclust()
. You can sample e.g. 5000 rows from 70k rows. For the heatmap visualization, it is basically the same.
@jokergoo Looks like: https://github.com/cran/fastcluster
fastcluster::hclust
could help with this issue: https://github.com/jcao89757/TESSA
Trying to change the clustering method solves this problem,here is my code:
Heatmap(matrix =mat,
# cluster_columns = T,
# cluster_rows = T,
cluster_rows = function(x){genieclust::gclust(x,distance="euclidean")},
cluster_columns = function(x){genieclust::gclust(x,distance="euclidean")}
)