Short QSPR equations versus machine learning on small datasets
A two-term equation and a boosted ensemble answer the same question with different parameter budgets. On a few hundred molecules the validation bill is equal.
Updated November 28, 2026
A short QSPR equation and a machine-learning model answer the same question with different budgets. The equation spends two or three coefficients and a search. A boosted ensemble or a message-passing network spends thousands of parameters and a training loop. On a few hundred molecules the equation usually wins on stability and the model on flexibility, and both lose when the validation is weak.
Three coefficients against ten thousand parameters
A MolBasis kernel has the form ŷ = β₀ + Σ βⱼ·z(fⱼ^pⱼ), with one or two terms. Each term is a descriptor raised to an exponent from a grid, standardised, and weighted by a ridge coefficient. The whole model is three or five numbers, plus the names of the descriptors and their exponents. A random forest holds hundreds of trees with thousands of split points. A Chemprop model, described by Yang and colleagues in 2019, learns its own features from the molecular graph through message passing and carries far more weights than molecules in a typical property dataset.
Parameter count matters because variance grows with it. A model with many free parameters fitted on three hundred molecules will track noise unless something restrains it. Boosted trees restrain themselves with depth limits and shrinkage. Networks use dropout, weight decay and early stopping. Ridge regression, introduced by Hoerl and Kennard in 1970, restrains a linear fit with a penalty on the coefficients. The kernels use a very small penalty, so almost all of their restraint comes from having two terms at most.
The count hides one thing. The kernel's search over nine descriptors, an exponent grid and all pairs is itself a learning step with its own capacity. The guide on overfitting with few parameters shows why the search, not the coefficient count, sets the optimism of a short equation.
What a machine-learning model buys
Flexibility. A boosted ensemble fits a different slope in different regions of descriptor space and finds interactions nobody wrote down. A graph network needs no descriptors at all and improves as data grows. On datasets of tens of thousands of measurements these models have become the usual choice, and a reader entering chemistry from another field will recognise the pattern. More data, more capacity, better fit.
Property datasets are rarely that large. The ESOL set of Delaney, the FreeSolv set and the Bradley melting-point set all hold hundreds to a few thousand molecules. At that size a network's test error is dominated by variance from the training sample, and a change of random seed moves the figure. Fingerprint inputs add thousands of sparse columns that a linear model cannot use well but trees can. The gain is real when the data supports it and illusory when it does not, and only the test set tells which.
What a short equation buys
Inspectability and cheap use. A two-term equation on cavity area and σ variance can be read, differentiated and argued with. Its applicability domain is a box in a space of two descriptors. If the coefficients are published, anyone with the same descriptor file applies it in one line. The guide on interpretability of short equations is careful about how far that reading goes, since an exponent of 1.25 chosen from a grid is not a physical law.
The second term earns its place only when the data says so. The MolBasis record applies a feature-addition test and a held-out gate before a second term is kept, and three equations once shown with two terms are now shown with one after a correction described on the findings page. That correction is a reminder that a small model can still be presented wrongly.
The validation bill is the same for both
Whatever the model, the questions a reviewer asks do not change. Was the test set separated by scaffold or by time, not at random. Does the figure beat a baseline that predicts the training mean. Does a permutation of the target destroy the result. How many molecules does the held-out figure rest on. The guide on scaffold-blind versus time split covers the first question, and the guide on permutation tests and y-scrambling covers the third.
Machine-learning models add hyperparameters, so they need nested cross-validation to choose depth or learning rate without touching the test set. Short equations add a search, so they need a permutation floor to show that the winning descriptor beats noise. Neither is exempt. Each MolBasis kernel page states its held-out r on a 25 percent scaffold-blind split with one seed and no confidence interval, and the methodology page lists the rest of the gate.
A fair head-to-head in scikit-learn
The only honest comparison runs both models through the same grouped folds and the same baseline. This sketch does that with ridge on two descriptors and gradient boosting on all nine, grouped by scaffold identifier.
import numpy as np
from sklearn.ensemble import GradientBoostingRegressor
from sklearn.linear_model import Ridge
from sklearn.model_selection import GroupKFold
from sklearn.pipeline import make_pipeline
from sklearn.preprocessing import StandardScaler
# X: descriptors, y: target, groups: Bemis-Murcko scaffold per molecule
ridge = make_pipeline(StandardScaler(), Ridge(alpha=1e-3))
gbrt = GradientBoostingRegressor(n_estimators=300, max_depth=3, learning_rate=0.05)
cv = GroupKFold(n_splits=5)
for name, model, cols in [("ridge", ridge, [0, 4]), ("gbrt", gbrt, list(range(9)))]:
mae_model, mae_base = [], []
for tr, te in cv.split(X, y, groups):
model.fit(X[tr][:, cols], y[tr])
pred = model.predict(X[te][:, cols])
mae_model.append(np.mean(np.abs(pred - y[te])))
mae_base.append(np.mean(np.abs(y[tr].mean() - y[te])))
print(name, 1 - np.mean(mae_model) / np.mean(mae_base))The printed number is the MAE lift over the mean baseline. Run it with several seeds for the fold assignment before believing a difference between the two rows.
Picking one for your problem
With a few hundred molecules, a handful of physically meaningful descriptors and a need to explain the result to a chemist, start with the short equation. With tens of thousands of molecules, fingerprints or graphs, and a need for the lowest error, start with the learned model. In between, run both on the same splits and report both. MolBasis publishes no comparison of its kernels against any other method on the same molecules, so its pages cannot settle this choice for you.
Key points
- A short equation has few coefficients but its descriptor search is a learning step with real capacity.
- Learned models gain from large data and lose to variance on a few hundred molecules.
- Both need grouped or scaffold-blind splits, a baseline, and a permutation floor.
- Compare models only on the same folds with the same baseline and several seeds.
- MolBasis reports kernel figures without any comparison to another method.
Questions people ask
- Is a short QSPR equation just a weak machine-learning model?
- It is a very small model chosen by a search, which is itself a learning step. On a few hundred molecules its low variance is an asset. On tens of thousands of molecules a graph network or a boosted ensemble usually captures more, at the cost of inspectability.
- Do short equations need less validation than neural networks?
- No. The search over descriptors and exponents can overfit as surely as a network can, and a permutation test, a scaffold-blind split and a baseline comparison are needed for both. Fewer parameters does not mean fewer ways to fool yourself.
- When does gradient boosting beat a linear equation on property data?
- When the dataset is large enough to estimate interactions and non-linear shapes, and when the inputs are many, such as fingerprints. On a few hundred molecules with a handful of descriptors the two often tie within the noise of the test set.
- Can I compare a MolBasis kernel against my own model?
- Only by building the comparison yourself on the same molecules and the same split. MolBasis publishes no comparison with another method and does not publish coefficients, so its kernel figures are reported results, not a benchmark you can rerun.
Further reading
In practice: This site makes no comparison with another method on the same molecules, because no controlled comparison exists. The guides compare methods on their principles, not on numbers.
See the kernels themselves
Every kernel is shown with its held-out result, the number of molecules it rests on and what it cannot be trusted for.