Re: [R] PAM Clustering

2017-08-18 Thread Sema Atasever
Grazie mille, So grateful for your kindness in answering questions. Regards. On Thu, Aug 17, 2017 at 8:50 PM, Germano Rossi wrote: > Sorry, I never use pam. In the help, you can see that pam require a > dataframe OR a dissimilarity matrix. If diss=FALSE then

Re: [R] PAM Clustering

2017-08-17 Thread Germano Rossi
Sorry, I never use pam. In the help, you can see that pam require a dataframe OR a dissimilarity matrix. If diss=FALSE then "euclidean" was use.So, I interpret that a matrix of dissimilarity is generated automatically. Problems may be in your data. Indeed pam(ruspini, 4)$diss write a

Re: [R] PAM Clustering

2017-08-17 Thread Sema Atasever
Dear Germano, Thank you for your fast reply, In the above code, *MYData *is the actual data set. Do not we need to convert *MYData to *the dissimilarity matrix using *pam(as.dist(**MYData**), k = 10, diss = TRUE*)* code line?* *Regards.* On Thu, Aug 17, 2017 at 2:58 PM, Germano Rossi

Re: [R] PAM Clustering

2017-08-17 Thread Germano Rossi
try this MYdata <- read.csv2("data.txt",dec='.') library(cluster) cluster.pam = pam(MYdata,10) table(cluster.pam$clustering) filenameclu = paste("clusters", ".txt") write.table(cluster.pam$clustering, file=filenameclu,sep=",") 2017-08-17 10:28 GMT+02:00 Sema Atasever : >

Re: [R] PAM Clustering

2017-07-10 Thread Ulrik Stervbo
Hi Sema, read.csv2 use ',' as the decimal separator. Since '.' is used in your file, everything becomes a character which in turn makes pam complain that what you pass to the function isn't numeric. Use read.csv2("data.csv", dec = ".") and it should work. You can also use class(d) to check the

[R] PAM Clustering

2017-07-10 Thread Sema Atasever
Dear Authorized Sir / Madam, I have an R script file in which it includes PAM Clustering codes: *when i ran R script i am getting this error:* *Error in pam(d, 10) : x is not a numeric dataframe or matrix.* *Execution halted* How can i fix this error? Thanks in advance. ​ data.csv

[R] PAM Clustering Ignores Cluster Number Parameter

2011-05-18 Thread Dario Strbenac
I am using PAM with k = 10 clusters, but I only get one cluster ID for all my observations. I couldn't find any discussion about this in the help file, or mailing lists. Is there a reasonable explanation for this result ? cIDs - pam(all, 10, cluster.only = TRUE, do.swap = FALSE) table(cIDs)

Re: [R] pam() clustering for large data sets

2011-05-17 Thread Christian Hennig
Dear Lilia, I'm not sure whether this is particularly helpful in your situation, but sometimes it is possible to emulate the same (or approximately the same) distance measure as Euclidean distance between points that are somehow rescaled and retransformed. In this case, you can rescale and

[R] pam() clustering for large data sets

2011-05-16 Thread Lilia Nedialkova
Hello everyone, I need to do k-medoids clustering for data which consists of 50,000 observations. I have computed distances between the observations separately and tried to use those with pam(). I got the cannot allocate vector of length error and I realize this job is too memory intensive. I