An interactive Streamlit dashboard for exploring and applying clustering algorithms to your own data. Upload any CSV, preprocess it, and experiment with multiple clustering methods and visualizations — no coding required.
- Upload any CSV file and preview it instantly
- Optionally designate an ID column that is excluded from clustering but preserved in the output
- Automatic detection of non-numeric columns, with a one-click option to remove them
- Missing value detection with an option to drop incomplete rows
- Automatic standardization (zero mean, unit variance) before clustering
- Optional PCA with a configurable number of components
- Explained variance bar chart and cumulative variance breakdown per component
- Cluster on the raw features or on the PCA-reduced space
| Algorithm | Tuning Aids |
|---|---|
| KMeans | Elbow method plot |
| Gaussian Mixture Model | AIC / BIC plot, choice of covariance type |
| DBSCAN | k-distance plot to guide eps selection |
| Agglomerative Clustering | Interactive dendrogram with truncation control |
| Spectral Clustering | Configurable number of nearest neighbors |
- Cluster centroid means and within-cluster variances on the original (non-standardized) scale
- DBSCAN noise-point count reported separately
- Download the full dataset with cluster labels as a CSV
- Pairwise Scatter Plot — all feature pairs colored by cluster label
- PCA 2D Scatter Plot — fast two-component projection of the clustering space
- t-SNE — non-linear 2D embedding with configurable perplexity, learning rate, and iterations
- Python 3.8 or higher
git clone https://github.com/egeozkoc/clustering-toolbox.git
cd clustering-toolbox
pip install -r requirements.txtstreamlit run Streamlit_Clustering_Toolbox.pyThe app will open in your browser at http://localhost:8501.
- Upload a CSV file using the file uploader.
- Select an ID column if your data has a row identifier you want to keep but not cluster on.
- Remove non-numeric columns if the dataset contains categorical or text fields.
- Select features to include in clustering using the multiselect widget.
- Remove missing rows if your data has NaN values.
- Optionally apply PCA to reduce dimensionality before clustering.
- Choose a clustering algorithm and tune its parameters using the interactive controls.
- Inspect the cluster labels, centroid statistics, and visualizations.
- Download the labeled dataset as a CSV.
| Package | Purpose |
|---|---|
streamlit |
Dashboard framework |
pandas |
Data loading and manipulation |
numpy |
Numerical operations |
scikit-learn |
Clustering algorithms, PCA, t-SNE, scaling |
scipy |
Hierarchical linkage and dendrogram rendering |
matplotlib |
Plot rendering |
seaborn |
Statistical visualizations |