Chemometrics#
The Chemometrics page compares a set of spectra against each other: it bins them onto a common axis, decomposes the result into principal components, clusters the samples, and runs STOCSY to find resonances that move together.
It works on a set of scans, not a single one. Pick the set at the top of the page, then build the matrix.

Building the matrix#
Every spectrum is integrated into fixed-width buckets so that all samples share one axis. The left rail controls how that is done, and the settings stay on screen beside the result because they decide which components exist at all.
| Setting | What it does |
|---|---|
| Bin width | Width of each bucket, in ppm. Wider bins absorb shift drift between samples; narrower bins keep close resonances apart. |
| From / To | The ppm window to bin over. |
| Excluded regions | Ranges dropped before analysis. Residual water and the solvent region dominate every component unless they are removed — there is a Water 4.5–5.0 preset for the usual case. |
| Normalisation | Total area, PQN, a reference region, or none. Puts samples on a comparable scale before they are compared. |
| Scaling | Mean-centre, Pareto, unit variance, or none. Decides how much a quiet bin counts against a loud one; Pareto sits between no scaling and unit variance. |
| Components | How many principal components to compute. |
Press Build matrix to run. The header reports the applied settings alongside the planned ones, and marks the figures stale when you change a setting without rebuilding — the numbers on screen were built from the old matrix until you press Rebuild.
Warning
Without centring, the first principal component describes the mean spectrum rather than the variation in it. The page warns when a result was computed on an uncentred matrix.
Scores#
The scores plot places the samples on two chosen components. Pick the horizontal and vertical component, and colour the points either by a sample attribute or by the clusters the last run found.
The Hotelling's T² 95% ellipse draws the limit of the model on the two components shown. A sample outside it is unusual; a sample inside it may still be flagged by a component that is not on screen, so the outlier list is the authority rather than the drawing.
Loadings#
Scores place the samples; loadings say which resonances moved them. The loadings view plots one component against chemical shift and lists its driving resonances — the strongest loadings, resolved back to peaks.
Pick a driver from that list to carry it straight into STOCSY.

Clustering#
Hierarchical clustering produces the dendrogram; the cut height turns it into a fixed number of clusters. k-means is available alongside it.
The distance and the linkage decide the tree as much as the data does, so both are reported in the view title. Ward and centroid linkage are defined on Euclidean distances only, and the page enforces that.
Quality figures accompany the tree: the cophenetic correlation says how well the tree summarises the underlying distances — below about 0.7 it is a poor summary — plus inertia and silhouette for the k-means partition.
STOCSY#
STOCSY takes one chemical shift as the driver and asks what else in the dataset co-varies with it. Height is the covariance with the driver and colour is the absolute correlation, so resonances of the same molecule stand out as a set.
Set the driver shift directly, or send one across from the loadings list. The driver snaps to the nearest bin. Raise the |r| cutoff to keep only strong correlations; the correlated-shifts list reports what clears it.

The matrix has to exist before the driver can be moved — build it first.
Exporting tables#
The CSV button in the top strip writes the open view: sample scores (with Hotelling T² and Q residuals), loadings per bin for every component, or the STOCSY covariance, correlation and significance per bin. The dendrogram has no table to export. Values are unrounded and the file is named after the view.