Scatterplot matrixEvery pair at once.
A grid of small scatter plots, one for every pair of numbers. Scan it for the cells where the dots form a line.
- Answers Do two things move together?
- Your data several numbers per item
- Numbers about 3 to 6
- Cells one per pair, mirrored
- Excel and Power BI not built in
What is a scatterplot matrix?
A scatterplot matrix (also a SPLOM or pairs plot) is a grid of small scatter plots, one for every pair of numbers in a table. The diagonal names each number; every other cell plots one number against another. Scanning the grid shows at once which pairs move together, which do not, and where odd items sit.
An estate agent has 12 houses with four numbers each: size, rooms, age and price. In the grid, size against price makes a clear rising line; age against price falls.
Why use a scatterplot matrix?
Because it checks every pair of numbers in one picture.
- Every pair. Four numbers give six pairs, all in one grid.
- Real dots. Unlike a single number per pair, the shape of each link shows.
- Finds surprises. A curve, two groups or an odd item in one cell.
- A first look. The quickest way into a new table of numbers.
How does a scatterplot matrix work?
Four steps build the grid.
- Step 1 of 4One scatterSize across, rooms up: one pair.
- Step 2 of 4A row and a column per numberFour numbers make a four by four grid.
- Step 3 of 4Fill every cellEach cell plots its column's number across and its row's number up.
- Step 4 of 4The diagonal names themA number against itself is a straight line, so its cell carries its name.
The grid is a mirror: the cell for price against size and the one for size against price show the same pairs, turned over.
What are the parts of a scatterplot matrix?
Four parts, and each one has a job.
- Diagonalthe number this row and column are about
- Cellone pair, as a small scatter plot
- Mirror cellthe same pair, axes swapped
- Bottom rowthe last number, here price, against each of the others
How do you read a scatterplot matrix?
Three looks, in this order.
- Find the tight linesSize against price, and size against rooms: the dots form clear rising lines.
- Find the falling onesAge against price falls: older houses tend to cost less.
- Find the cloudsAge against size is a loose cloud: no clear link.
What kinds of scatterplot matrix are there?
The same houses, three ways.
- Kind 1Full gridEvery pair, both ways round.
- Kind 2Numbers insteadEach pair as one number: how strongly they move together.
- Together
- Opposite
- Kind 3Half the numbersOnly the lower half, since the grid is a mirror.
- Together
- Opposite
Tools often put a histogram of each number on the diagonal, or colour the dots by a group.
When should you use a scatterplot matrix?
When you have a few numbers per item and want to see how all of them relate.
- there are about 3 to 6 numbers
- you explore a new table
- the shape of each link matters
- there are enough items to see a pattern
- there are many numbers (a correlation matrix)
- one pair is the story (one scatter plot)
- the reader wants a single answer (a bar chart)
Scatterplot matrix or correlation matrix?
Dots for the shapes, numbers for the overview.
- Together
- Opposite
The scatterplot matrix shows every dot, so a curve or two groups inside one pair stay visible. The correlation matrix turns each pair into one number and a colour: faster to scan, and it fits many more numbers, but a curve and a straight line can get the same number.
How do you make a scatterplot matrix?
Not built into Excel or Power BI; one line in Python or R.
In Python, seaborn's pairplot draws one from a table, with histograms on the diagonal; pandas has scatter_matrix. In R, pairs() draws one in base R and GGally's ggpairs in ggplot2. In Power BI, run that code in a Python or R visual (Python and R visuals in Power BI); for "what drives this number?", the key influencers visual is the built-in alternative.
What goes wrong with scatterplot matrices?
The most common mistake, and its fix: too many numbers.
- about 3 to 6 numbers
- a correlation matrix to pick them, then a scatterplot matrix of the best
| Mistake | Why it hurts | Fix |
|---|---|---|
| Too many numbers | Cells become specks | About 3 to 6, picked first |
| No names on the diagonal | Readers lose which cell is which | Names on the diagonal |
| Different scales per cell, unsaid | Cells look more alike than they are | Say each cell has its own scale |
| Too many dots | Each cell is a blob | See-through dots or a sample |
| Reading links as causes | Same as any scatter | Say "goes with" |
Every chart for “Do two things move together?”
- Two numbersScatter plotOne dot per item, two numbers as its position.
- Two numbersTrend lineThe straight line that best fits a scatter of dots.
- Two numbersHexbin plotA scatter with too many dots, counted in hexagons.
- Two numbersContour plotRings around where dots crowd, like height lines on a map.
- Three numbersBubble chartA scatter plot whose dot size is a third number.
- Many numbersCorrelation matrixA grid of how strongly each pair of numbers moves together.
- Two categoriesHeat mapA grid where colour shows the value, so patterns jump out.
- Two categoriesQuadrant chartA scatter split into four boxes, for sorting items into groups.
Read on, step by step.
Does it fit your data? Try it.
Paste your table into Chart Compass, say what the chart should show, and see the charts that fit, drawn with your own numbers. It runs in your browser, so the data stays with you.