SOM Map
The SOM Map widget trains a self-organizing map on the standardized feature space and displays it as a topology-preserving 2D grid.
It can switch among three views: the U-matrix (neighbor-cell distances, revealing cluster boundaries), component planes (how one variable changes across the map), and hit counts (how many trials fall onto each cell).
A SOM maps high-dimensional trial space onto a 2D lattice. Cells that are near each other on the grid are trained to represent similar points in the original space. Rather than forcing a fixed number of clusters, it provides a continuous map for reading cluster-like regions, gradients, and outliers.
Learning intuition
1. Standardization
Input columns are standardized to zero mean and unit variance before training. This prevents distance calculations from being dominated by columns that simply have larger numeric scales.
2. BMU (Best Matching Unit)
Each data point is assigned to the node whose weight vector is closest:
3. Batch update
Tunny Dashboard uses batch SOM. Instead of updating one sample at a time, each epoch first computes BMUs for all points, then updates each node weight using a Gaussian-neighborhood weighted average:
is grid distance and is neighborhood radius. As learning proceeds, the neighborhood shrinks: early epochs shape global structure, later epochs refine local structure.
4. Deterministic initialization
Initialization is not random. As in PCA Biplot, the map is placed using the first two principal-component directions. So with the same data and settings, the map is reproducible.
Reading the three views
- U-matrix: mean distance from each cell to its up/down/left/right neighbors. High-value ridges indicate boundaries between dissimilar regions.
- Component planes: for each variable, shows how its node weights vary across the map.
- Hit counts: number of trials assigned to each cell, useful for seeing dense and sparse regions.
Caveats
- Too few nodes reduce resolution by collapsing different trials into the same cells; too many nodes create many empty cells and noisy U-matrices.
- Topology preservation is approximate, not guaranteed. Folding high-dimensional structure into 2D can still introduce local distortions.
- U-matrix boundaries are visual cues, not statistical significance tests. Interpret together with component planes and hit counts.
References
- Kohonen, T. (1982). Self-organized formation of topologically correct feature maps. Biological Cybernetics, 43(1), 59-69. https://doi.org/10.1007/BF00337288