I created a clusplot from PAM results. It represents how signals have been 
classified.
Signals are identified by a numerical label.
My trial distance matrix is made up of 10 rows, one for eacjh signal.
I assigned the signals iidentifiers  as rownames of the distance matrix.

rwn
 [1] "1104" "1332" "2057" "2425" "2483" "2530" "2649" "2881" "3044" "877" 

The rownames order correspond to the ordering of signal features used in the 
distance matrix.
This way I can click on each point of the clusplot and make the signal 
identifier pop up on the canvas using the following 
commands sequence:

 yy <- as.matrix(dist.mat)
 rownames(yy) <- rwn
 cl <- pam(dist.mat,2,diss=TRUE)
 x11(width=22,height=20)
 if(interactive()) { 
    clusplot(yy, cl$cluster, 
diss=FALSE,shade=TRUE,color=TRUE,labels=5,col.p="orangered3",
             main="G1-INDEX  Clusters Best Layout",col.main="coral4", 
             col.txt="black",font.main=2,font.lab=4,font.axis=2,font.lab=4)  
 }
## WAIT FOR MOUSE INPUT TO DELETE CURRENT SCREEN PLOT
 coord <- locator(n=1)
 graphics.off()

I cannot get the signal identifier returned to a script variable besides being 
printed on the plot.
Any help is more than welcome.

Thank you in advance,
Maura




tutti i telefonini TIM!


        [[alternative HTML version deleted]]

______________________________________________
[email protected] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to