Consensus tree or "bootstrap proportions" from multiple hclust objects
I have a list of hclust objects resulting from slight variations in one variable (for calculating the distance matrix)
- now I would like to make a consensus tree from this list.
Is there a generic package to do this? I am hacking my way through some code from maanova and it seems to work - but it's ugly and it needs a lot of hacking since I am not doing "normal" bootstrapping (it's chemical data).
/Palle Villesen, Denmark
c1_list <- seq(10,100,by=10)
c2 <- 30
e<- 1
mboot <- list()
for (i in 1: length(c1_list) ) {
c1 <- c1_list[i]
cat("Doing C1=",c1,"...")
x <- hclust(custom_euclidean(t(log2(data[, all]+1)), c1,c2,e), method='average')
cat("..done\n")
mboo开发者_C百科t[[i]] <- x # To get hclust object back use mbot[[i]] to get i'th object
}
#### Now extract the robust groups from mboot...
First, have a look at Allan Tucker's code for consensus clustering, related to his paper "Consensus Clustering and Functional Interpretation of Gene Expression Data".
Here are a few other pointers:
- You mentioned that you're using the maanova package; this can build a consensus tree out of bootstrap cluster result with the
consensus()
function. Have you tried that? - The ape package is intended for phylogenetic tree analysis, so it's possibly not completely relevant, but you might look into it. There is an example using hclust on R-Help.
- Similarly, the nem package, which is part of bioconductor has some examples.
Hm, that sounds like a boosting approach applied to clustering, and a quick Google search reveals quite an existing literature on boosting clustering. Maybe that is a start?
As for R code, there are always the Task Views on Clustering and Machine Learning.
精彩评论