Questions tagged [k-means]

k-means is a method to partition data into clusters by finding a specified number of means, k, s.t. when data are assigned to clusters w/ the nearest mean, the w/i cluster sum of squares is minimized

Filter by
Sorted by
Tagged with
0
votes
0answers
7 views

How to show that GMM has the same assignment done as k-mean when the covariance is 0?

Given a Gaussian mixture \begin{equation}p(x) = \sum_{k=1}^{K}\pi_kN(x:M_k,\sum)\end{equation} with fixed uniform mixing weights $\pi_k = 1/k$ and has the same fixed isotropic covariance matrix $\sum ...
0
votes
0answers
12 views

Check when dataset should be splitted [closed]

I have a dataset where I need to say if it could be divided into two or more to help the AI to classify that dataframe. Therefore, I applied the elbow method and the silhouette to see into how many ...
1
vote
0answers
5 views

Dimension reduction - doing a PCA on the coordinates of a MCA

I have a dataset with 25 continuous variables and 2 categorical variables. I want to perform k-means clustering, so as a previous step I am performing a multiple correspondence analysis on the ...
0
votes
0answers
27 views

K-Means and HCA comparison to a model solution

I’m running several cluster analyses on related datasets and would like to find out which one is closest to the benchmarks/model solutions I would expect based on theory (or otherwise which benchmark ...
0
votes
1answer
24 views

K-means to cluster texts, scaling

I want to cluster a folder of texts. I created a data file where for each text, I write whether a certain word appears in it or not. I want to cluster according to this. So my matrix is globally only ...
0
votes
0answers
17 views

t-SNE Clustering

I have about 500 users and their travel behavior as 100-dimensional vectors, created with a doc2vec approach. Using tensorboard´s embedding projector I can visualize these in a 3 or 2 dimensional ...
3
votes
1answer
46 views

Why are K-means and GMM (Gaussian Mixture Models) not suitable for discovering clusters with non-convexs shapes?

I have seen that mainly here and from a lot of resources that K-means and Hello all! Gaussian mixtures are not suitable for detecting clusters with non-convex shapes. I know that because both ...
1
vote
1answer
27 views

No clear elbow and low Silhouette scores K-Means

I am implementing the K-Means algorithm to group books based on their title and their description. I pre-processed the data merging the fields and deleting all the punctuations and some undesirables ...
0
votes
0answers
29 views

Perform k-means clustering after MCA for transforming categorical variables - provide weights to variables?

I have a very dataset with many observations (> 1 million), with mainly continuous variables and three categorical variables. After searching for clustering methods for mixed data, I decided to ...
0
votes
1answer
19 views

Elbow method gives very different number of clusters than Silhouette method in kmeans

I am trying to cluster tweets using k means algorithm. In order to find the best number of clusters I run the elbow method and the Silhouette method for 1 to 14 clusters. However, the elbow method ...
1
vote
1answer
129 views

Why is K-Means a special case of Mean-Shift algorithm?

I have read the paper of Yizong Cheng about Mean Shift, Mean shift, mode seeking, and clustering , but I didn't understand exactly, how did he concluded that KMeans is a Special case of Mean Shift ...
0
votes
0answers
19 views

k-means with soft constraints (KSC) algorithm: how to minimize objective function?

I'm learning about the KSC algorithm as described in "Clustering with Missing Values: No Imputation Required" by Kiri Wagstaff. Here's a small dataset to use as an example: ...
0
votes
0answers
32 views

K-means gives same output in prediction

I am using K-means from the sklearn library to cluster/group data (more than 2 GB). Training, saving and predicting is done as follows : ...
1
vote
1answer
23 views

Clustering - Different algorithms, same results

I'm working on my first clustering assignement and I've ran K-Means, Spectral clustering, Hierarchical clustering and Mini-Batch K-Means on same data and received the exact same results (cluster sizes,...
0
votes
1answer
63 views

In k-means or kNN, we use euclidean distance to calculate the distance between nearest neighbours. Why not manhattan distance?

In k-means or kNN, we use euclidean distance to calculate the distance between nearest neighbours. Why not manhattan distance ?
0
votes
0answers
13 views

Variables information in cluster analysis

I am performing cluster analysis using kmean clustering. And I would like to understand impact of each variable which where used in cluster formation, which variable contributed to the clusters the ...
0
votes
1answer
23 views

Mini batch K means: how is it guaranteed that at the end every element is labeled?

I'm trying to completely understand Mini Batch K means After reading the following pseudo code ... We all know that in every iteration, you choose a fixed size ...
1
vote
1answer
74 views

How come Mini Batch K means partial_fit method be useful for stream clustering?

Currently, I'm studying the advance in cluster analysis regarding stream clustering. I ended up assessing Mini batch K means because of some comments I read on the Internet, like the following one: ...
1
vote
1answer
22 views

Understanding PAM - why is it greedy?

I've been studying k-medoids for a while but i can't understand the first step or BUILD step: in particular i can't get how the initial medoids would be "greedy". I'm not much confident with the ...
0
votes
1answer
113 views

Why is k correlated with the mean and variance of the distance between centroids in k-means?

I've noticed that if I'm doing k-means clustering (in MATLAB) on basically any set of data (not randomness), the mean and variance in centroid linkage distance appears to always be approximately ...
1
vote
1answer
24 views

Correct clustering approach for segmenting stores

Domain : Retail I have a set of stores which I want to cluster into similar stores based on 10 variables: revenue, avg income, market share etc. I took 2 approach: Approach 1: Given there are 10 ...
0
votes
0answers
96 views

K-Means Unable to Detect Small Clusters

I am just wondering about this issue brought up by our teacher about a drawback of K-means being unable to detect small clusters. It's homework that we should come up with ideas about why this is so ...
0
votes
1answer
35 views

k-means method clarification

I am pretty new to k-means and cluster analysis methods, but I am trying to do it on 5 different measures of inequality and redistribution (Gini, P90/P10, Atkinson with different parameters and the ...
0
votes
2answers
20 views

Scaling in clustering with k-means

I have a set of data on revenue and cost in 2 different currencies A and B. So I am just curious if k-means result changes if I make the following modification a) If I run k-means once with currency ...
0
votes
3answers
38 views

How to identify or give a meaning to the cluster membership in a hierarchical clustering?

I know clustering is a type of unsupervised learning problem, however when Kmean clustering is used one can sort the membership based on the cluster centers. For example consider the cluster ...
1
vote
3answers
146 views

k-means clustering with some known centers

I am working on an project where I need to add clusters (likely double but I want it to be arbitrary) to an existing kmeans clustering solution. I am actually only interested in the centers. So is ...
0
votes
0answers
12 views

Question About Coming Up With Own Function for Distance Matrix (For Clustering)

Right now, I am currently working on implementing a clustering algorithm with millions data entries with regards to game users for a mobile game. A lot of the features I plan on using are unique to ...
0
votes
0answers
37 views

Which one is the best way when data preprocessing for right skewed data for clustering?

Nowadays, I am studying clustering. The question arises when processing data that is highly skewed to the right (like below). Generally, known processing methods are log transformation, power ...
0
votes
1answer
16 views

Cluster validation based on cluster statistics

Hi everyone I am comparing two models clusters statistics to know which one is "better", but the output or model summary varies on the algorithm used. Both models have the same data and the same ...
1
vote
1answer
27 views

Modifying k-means for points on torus

My data coordinates are degrees so each axis has values [-180, 180]. Therefore it's easy to spot that in fact the scatter plot on the right end continues on the left side and the same thing for up and ...
0
votes
2answers
45 views

K-means which normalization fits

Hi am working on a business dataset, where I want to group the participant in k-means based on some features. The problem is I have to create this features upfront, so that I combine different ...
0
votes
1answer
41 views

How to compute probability distribution to initialize k-means++ cluster centroids?

I am trying to implement my own k-means algorithm without external libraries/modules (with the exception of numpy). I have recently learned about the k-means++ algorithm; to my understanding, it ...
0
votes
0answers
28 views

Can a k-means cluster use different measures for homogeneity and heterogeneity?

TL;DR: Is there an existing k-means clustering algorithm that can have different weights for the (minimized) in-group distance measure and the (maximized) between-group measure? Or, better yet, can ...
7
votes
2answers
1k views

Can k-means be used for non normally distributed data?

I read a lot of papers that test k-means with many datasets that are not normally distributed like the iris dataset and get good results. Since, I understand that k-means is for normally distributed ...
0
votes
0answers
34 views

SSE for K-means and K-medoids

I am trying to understand given same data set and same K - will the SSE of K means be higher than K Medoids or not. both try to minimize the SSE and K-medoids is more robust to outliers - does it mean ...
0
votes
1answer
109 views

K-means classifies 96% of my data in 1 cluster. Any suggestions to improve the results?

Problem: K-Means clustering shows 96% of my data belongs to one cluster. How can I improve my results or should I conclude that no cluster exists in my dataset. Dbscan clustering shows 1 cluster ...
1
vote
1answer
50 views

K-Means clustering: optimal clusters for common data sets

I use scikit-learn to get IRIS and WINE clusters for evaluating an algorithm for K-means clustering. The K-means algorithm is a heuristic algorithm for solving the "minimum-sum-of-squares-clustering (...
0
votes
0answers
43 views

How to search for irregular signals: Fourier, DWT or k-means?

See my notebook here I want to search for irregular time signals in a data set of ~3 500 000 time signals. I can't give a clear definition of irregular signal, but it must fulfil the criteria of: not ...
0
votes
1answer
48 views

How to interpret the different cluster sizes in Silhouette plot?

I created silhouette plots for my clustering models by following: this link I want to know what does the different cluster sizes mean and how they were generated?? I understand that thicker size ...
0
votes
1answer
84 views

SSE not decreasing with increase in number of clusters

So as far as I know, SSE should decrease( or just never increases) as the number of clusters increases. I have an implementation of K-means where the parameter k was supplied as 5,10,15,20,25 and 30 ...
0
votes
0answers
17 views

Dimensions in Kmeans cluster plot [duplicate]

I did a kmeans cluster plot to identify how my plants cluster based on 4 morphological traits of them. It gave me 3 clusters as shown in the figure. I'm not sure how to interpret these dimensions ...
0
votes
0answers
18 views

K means clustering on principle components with low explained variance ratios?

Say I have a situation where I do PCA with three components on a data set and the summed explained variance ratios of the three components is relatively low, say less than 0.5. If I were to then do k ...
1
vote
1answer
17 views

Using k-means to segment customers in the positive class

I have some labeled data (0=didn’t cancel, 1=canceled) that I am creating a model for in my marketing class. On top of predicting who is likely to cancel, I’d like to explore the possibility of ...
0
votes
0answers
27 views

Spectral relaxation for k-means clustering

In the paper "Spectral Relaxation for K-means Clustering" the authors transform k-means objective into the trace maximization of the matrix ($H^T * X*X^T *H$), where $X$ is a ($n \times m$) data ...
0
votes
1answer
29 views

k-means clustering issue voice data

I'm getting an issue in my k-means I don't know if it my data-set or what anything else. Why i got thia flowing point in the right side of the image? ...
0
votes
1answer
53 views

How to find better solutions for the k-means problem than by using the k-means/k-means++ algorithm?

The $k$-means problem in its common form can be stated as follows: Given a data set $\mathcal{X}=x_1, ..., x_n$ consisting of $d$-dimensional vectors find a set $C = c_1,...,c_k$ of $d$-dimensional ...
0
votes
0answers
11 views

Clustering a long list of non-english sentences into contextual similarity groups

I had machine learning transcribe 2597 german audio files into a CSV file. Output quality is a little bit worse than youtube's transcription. Also, all words are lowercase. It has the pattern of <...
1
vote
1answer
57 views

How to merge two different sum of squared errors?

Given two datasets $ U \in R$ and $P \in R$. $n_1$ and $n_2$ are respectively the number of points contained in U and P. The sum of squared errors of U and P are as follow: $$ SSE_U=\sum_{i=1}^{n_1}||...
-1
votes
1answer
23 views

How do i cluster these data?

So basically, I have this data: ...
0
votes
1answer
71 views

Can I perform a t-test to show that cluster means are different?

I'm looking at performing k-means clustering on a dataset with 5 continuous variables. The clusters that I find however, look very similar except in one dimension e.g cluster 1 : low avg income, ...