Home▸AI & Machine Learning▸News Article Clusterer (2D): TF-IDF + Hierarchical Clustering

News Article Clusterer (2D): TF-IDF + Hierarchical Clustering

2D flat-panel lab: real TF-IDF vectors and agglomerative hierarchical clustering group synthetic news articles into topics, shown as a PCA scatter plot next to a live dendrogram.

AI & Machine Learning2DModerate60 FPS📱 Mobile-adapted⇄ 3D version
2d-ai-news-article-clustering ↗ Open standalone

This 2D companion runs the exact same pipeline as the 3D version — real TF-IDF vectorization, agglomerative hierarchical clustering by cosine distance, and PCA via power iteration — on a flat scatter plot and dendrogram instead of an orbiting 3D scene, so the cluster structure is easier to read at a glance.

⚙ Under the hood

A synthetic corpus of documents is vectorized with real TF-IDF weights, then merged bottom-up by agglomerative clustering (average or complete linkage on cosine distance) into the dendrogram shown below; the scatter plot projects each document onto its top 2 principal components found by power iteration.

tf-idfhierarchical clusteringdendrogramprincipal component analysis

2D · HTML5 Canvas 2D · 60 FPS target · runs fully client-side, no install

What did you find?

Add reproduction steps (optional)