Live demo
Correlation matrix
Which of these biomarkers, or which visits of one biomarker, are related? A grid over a set of variables: below the diagonal a mark sized and coloured by R's coefficient, above it the number, with the pair count of every cell, for Pearson or Spearman on the participants who have both values. It prints no p-value. It opens on every biomarker at the first visit, and a click on a cell opens that pair in the association scatter, with a way back. The data is the synthetic study: 200 made-up participants, and no real one.
- The chart opens on every biomarker at the first visit, Baseline: twelve biomarkers, sixty-six pairs. Below the diagonal a pair is a mark, wider and darker the stronger R's coefficient, a filled blue disc where it is positive and an orange ring where it is negative; above the diagonal is the coefficient itself. One pair was planted with a correlation, TNF-alpha with IL-10, true Pearson coefficient 0.6; the rest are unrelated by construction.
- Every coefficient is computed by R, on the participants who have both values of its pair, so each cell has its own count. R is started in this browser when the page opens: the line under the grid says it is waiting, and what that first start downloads, until R answers. Nothing leaves this machine, and the chart computes no coefficient itself, not for a number, a size or a colour.
- The grid prints no p-value, by design: sixty-six unadjusted tests at once is not a question. To test one pair, open it.
- Click a cell, or press Enter on it, to open that pair in the association scatter, in place: one point per participant, R's coefficient with its interval and p-value, and a fitted line. Back to the correlation matrix returns to the grid as it was. The method and the filters go with you.
- Under Variables choose biomarkers at one visit or the visits of one biomarker, the value, and which are in the grid. The grid draws at most twelve at a time and says how many it is showing of how many. With six or fewer, Small scatters draws each pair's points in place of its mark.
- Point at a cell, or move to it with the arrow keys, to read its coefficient, its interval and its pair count. The list under the grid has every pair with its count, in the order R returned them. On a phone the cells are too small to hold a number: both sides of the diagonal are marks, and the numbers are in that list.
- Under Statistics choose Pearson or Spearman, and the fewest complete pairs a cell needs: a cell with fewer shows R's reason and no number. Left empty, the minimum is R's own.
The controls, the filters, the listing, the participant profile and the Chart.js this chart draws with are safety.viz's, version 1.9.0, loaded beside bio.viz from a copy with a record of where it came from.
The statistics are gsm.bio's, version 0.1.0: R in this browser is given one file of R, copied from gsm.bio at commit 514cbc3 with a record of where it came from. The same file, run in desktop R on the rows this chart hands over, wrote the answers the browser tests hold this page to.