I do not really understand your question. You can use use kmeans but without the observations that include the NA values (e.g. by deleting whole rows in your observation matrix). If you want to keep the information in the valid observations of those rows, I fear you need to look for a clustering algorithm that can handle missing values. I doubt that there is a kmeans version that can. Think about inserting means of all other observations into the gaps, though this introduces bias as well.

Jannis

Raji schrieb:
Hi,

  I am using k means algorithm for clustering.My data contains a few null/NA
values.kmeans doesnt cluster with those values.Are there any option like
na.omit which can avoid these null values and cluster the remaining values?

Thanks,
Raji


______________________________________________
R-help@r-project.org 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