concordmap | R Documentation |
Label switching is a problem in interpreting the results of a cluster analysis that uses MCMC. Two clusterings may be the same but the labels of the clusters may change. In order to avoid this problem we create a square matrix with length and width equal to the number of features. The i,jth element is the proportion of times feature i and j are in the same cluster. A sorting algorythm puts the genes that are clustered together next to each other.
concordmap(supcluster.list, chains=1, sort.genes = FALSE,criteria=1)
supcluster.list |
The output of |
chains |
The chains to use in the clustering |
sort.genes |
If |
criteria |
Two genes are in the same cluster when the probability that they are in the same cluster is greater or equal to the criteria. |
If sort.genes=TRUE a three element list, the first element is a m x m matrix where m is the number of features and the second element is the ordering created by sorting algorythm that this matrix is in. The final element is the cluster membership for each of the genes. If sort genes=FALSE only the m x m matrix is returned.
David A. Schoenfeld, Jessie Hsu
supcluster
,,compare.chains
,beta.by.gene
##---- Should be DIRECTLY executable !! ---- ##-- ==> Define data, use random, ##-- or do help(data=index) for the standard data sets. #NOTE: only a small number of MCMC iterations are done due to time constraints dat=generate.cluster.data(.2,npats=40,clusts=c(12,8,5), sig=1,gamma=1,beta=c(-5,0,6))[[1]] us=supcluster(dat,outcome="outcome",features=1:25,maxclusters=4,nstart=20,n=40,nchains=2) ts1=concordmap(us,chains=1) #plot of the concord map image(1:25,1:25,ts1$map)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.