Hi All,

Having applied ONE clustering method separately to TWO (similar) type of
datasets, I wonder – how

a)      I can determine where the method worked better (not merely based on
visualizing the plots)!

b)      I can retrieve the clusters along with their respective contents.
For example: if two clusters A & B are found and the clusters contain
different genes, how to access & save the genes of A and B.



# Hierarchical clustering

Genes <- read.csv (file="xy.csv", header = TRUE)

Genes_2 <- read.csv (file="ab.csv", header = TRUE)

Hierarchy1 <- clust.cor.patient <- hclust(as.dist(1 - cor(Genes)), method =
"ward")

Hierarchy2 <-clust.cor.genes <- hclust(as.dist(1 - cor(Genes_2)), method =
"ward")



## I tried k-means too, using the following simple codes. But again, wonder
if it is possible to know in which dataset the method worked better.

 kmeans.Genes.fit <- kmeans (Genes, 2)

kmeans.Genes_2.fit <- kmeans (Genes_2, 2)

# table (kmeans.Genes.fit$cluster); table (kmeans.Genes_2.fit$cluster)



Thanks a lot.

Cheers,

Santana

	[[alternative HTML version deleted]]

