d3-module-faces
In this visualization, Chernoff faces encode multidimensional data about d3 modules in a log-scaled scatter plot, with the x-axis representing NPM downloads and the y-axis representing GitHub stars. Each module is depicted as a face whose features—face shape, hair, mouth, nose, eyes, and brows—map to attributes like dependents count, description length, downloads, GitHub contributors, issues, stars, and repo size. The faces are positioned using a force-directed simulation that nudges overlapping glyphs apart, while annotations with swoopy-drag call out notable clusters. The visualization uses Vue for structure and a hybrid SVG/WebGL rendering to support the animated, interactive scatter plot.
AI-generated descriptionTo visualize the d3 modules being used, I made a log scaled scatter plot of forced directed Chernoff faces. By transforming many different attributes of our dataset into friendly glyphs, Chernoff faces allow us to understand multidimensional datasets. The encoding scheme is probably self explanatory, but I've included it below just in case:
'face': ƒ('dependentsCount')
'hair': ƒ('description', 'length')
'mouth': ƒ('downloads')
'nosew': ƒ('githubContributers')
'noseh': ƒ('githubIssues')
'eyew': ƒ('githubStars')
'eyeh': d => Math.random()
'brow': ƒ('repoSize')
I used the following modules:
- swoopy-drag
- d3-jetpack-module
- d3-force-container
- d3-chernoff
- d3-axis
- d3-force
- d3-scale
- d3-request
- d3-selection
Data is from nprms.io - see download-data.js to your generate your own listing of modules with different data points.