pca clustering

Issue #846 resolved
Former user created an issue

I did a pca of my trajectory and I clustered the pc1-pc2 plane. I have obtained distinct grouping/clusters of frames. How can i identify the corresponding structures in those clusters? thanks Sandor

Comments (2)

  1. Xinqiu Yao

    If you used the R function hclust() followed by cutree(), then, the information you wanted is already there. For example,

    # Assume the distance matrix dd calculated from PC1-PC2 coordinates
    h <- hclust(dd)
    g <- cutree(h, k=3) # get 3 clusters
    

    The variable 'g' has the same length and order of the trajectory and gives the cluster ID of the corresponding structural frame. So, g[1] will the cluster ID for the frame No. 1, and so on.

  2. Log in to comment