Twenty-two paired measurements where neither axis is the truth. Ordinary least squares gives a slope of 0.96362; Deming at λ = 1 gives 0.99494 — 3.25% higher, and much closer to the 1.0 the methods were built to share. Least squares is biased toward zero whenever x carries error, and the bias grows with how noisy x is.
22 pairs · λ = 1 (orthogonal)
y = 0.99494x + 1.1834
Ordinary least squares on the same data gives a slope of 0.96362 and the regression run the other way gives 1.02760. The Deming slope lies between them by construction, and moving λ moves it across that range. The slope's 95% interval is 0.8682 to 1.1217, which contains 1.
Deming slope
0.99494
CI 0.868 to 1.122
Intercept
1.1834
CI -6.784 to 9.151
Least squares slope
0.96362
3.25% below Deming
Inverse regression
1.02760
the other extreme
λ is an assumption, not a measurement. At λ = 1 the slope is 0.99494; as λ grows it falls toward the least-squares value of 0.96362, and as λ shrinks it rises toward 1.02760. Those two ends differ by 0.06398 here, which is how much a guess about the instruments can move the answer.
Three lines through the same points
How λ moves the slope
The fitted slope at several assumed error-variance ratios
λ
Means
Slope
Intercept
0.25
X is noisier
1.01457
-0.1279
0.5
X is noisier
1.00583
0.4561
1
equally noisy
0.99494
1.1834
2
Y is noisier
0.98420
1.9005
4
Y is noisier
0.97580
2.4616
→ ∞
all error in Y
0.96362
3.2749
Error on both axes Symmetric in X and Y Jackknife intervals λ is your assumption
What this tool shows
On the shipped comparison, ordinary least squares gives a slope of 0.96362 and Deming at λ = 1 gives 0.99494. Least squares is biased toward zero whenever the x variable carries measurement error, and comparing two instruments guarantees that it does. Deming sits between least squares and the same fit run the other way round — 1.02760 here — and λ decides where.
Deming regression with the error-variance ratio λ as a visible control, not a hidden default
Ordinary least squares and the inverse regression printed as the two limits Deming lies between
Jackknife confidence intervals on both slope and intercept
The fitted line drawn against the least-squares line on the same points
A table of the slope at five values of λ, so the sensitivity to the assumption is visible
Orthogonal regression as the λ = 1 special case, named rather than assumed
Error on both axes Symmetric fit Jackknife intervals λ sensitivity table
λ is an assumption you supply. Estimate it from duplicates, do not guess.
Updated 13 September 2026 · Works in any browser, no installation
Deming regression fits a line when both variables carry measurement error. Ordinary least squares minimises vertical distances, which assumes the x values are exact; Deming minimises a weighted combination of both distances, with the weight set by λ — the ratio of the error variance in y to that in x. At λ = 1 it is orthogonal regression. Its one demand is that you supply λ, which the data cannot provide.
At a glance
Formula shown
With Sxx, Syy and Sxy the usual centred sums, the slope is b = [(Syy − λSxx) + √((Syy − λSxx)² + 4λSxy²)] / (2Sxy) and the intercept is ȳ − bx̄. As λ → ∞ this collapses to Sxy/Sxx, which is ordinary least squares; as λ → 0 it collapses to Syy/Sxy, the regression of x on y. At λ = 1 it is total least squares, whose line runs along the principal eigenvector of the covariance matrix — a completely different derivation that the verification suite computes independently and matches.
Scenario support
Comparing a new assay against a reference method, calibrating one instrument against another, any regression where the predictor is itself measured rather than set, allometric and isotope relationships in the natural sciences, and checking whether a least-squares slope below 1 reflects a real difference or just noise in the predictor.
Educational estimate
Planning support from the values you enter — not professional advice.
Least squares is biased toward zero, and it is not subtle
This is the effect the whole method exists for, and it is a bias rather than extra noise — more data does not fix it.
Measurement error in x pulls the least-squares slope toward zero. The amount is the reliability ratio: the slope is attenuated by var(true x) / (var(true x) + var(error in x)).
On the shipped preset that shows as 0.96362 against 0.99494. Two methods built to agree, and least squares reports a 3.6% shortfall that is an artefact.
The two methods were designed to have slope 1, and a method-comparison study that reported 0.964 would be read as a proportional difference between instruments. It is not.
The bias does not shrink with n. A thousand observations give a very precise estimate of the attenuated slope, which is the failure mode worth knowing about.
λ is an assumption, and it moves the answer
Deming trades an unrealistic assumption for a realistic one, and the realistic one still has to come from somewhere.
λ is the ratio of the error variance in y to that in x. It cannot be estimated from the paired data alone — nothing in the scatter separates error from real variation.
On the shipped data the slope runs 1.01457 at λ = 0.25, 0.99494 at λ = 1 and 0.97580 at λ = 4. A guess about the instruments moves the answer by 4%.
The right way to get λ is duplicate measurements. Run each method twice on the same subjects, take the variance of the within-method differences, and divide.
λ = 1 is the honest default when you have no duplicates, because it makes the fit symmetric — and the table on this page shows how far the answer could move if that default is wrong.
The test least squares fails
There is a simple check that a method-comparison fit either passes or does not, and ordinary regression does not.
Swap the two methods. The slope should invert exactly. If method Y is 1.05 times method X, then method X is 1/1.05 times method Y.
Deming at λ = 1 passes this to machine precision, which the verification suite asserts on 200 generated fits.
Least squares fails it by a wide margin. Regressing y on x and x on y gives 0.96362 and 1.02760 on the shipped data — two answers to the same question, differing by 6.6%.
Which of the two you get depends on which column you typed first, and there is no principled reason to prefer either when neither method is a reference standard.
λ = 1 is orthogonal regression, and that is a choice about units
Orthogonal regression — minimising perpendicular distance to the line — is the most familiar version of this idea and carries a hidden assumption of its own.
Perpendicular distance mixes the two axes, so it only means something when they are in comparable units.
Measure y in grams rather than kilograms and the orthogonal fit changes. That is not a bug: λ = 1 is the claim that the two methods have equal error variances, which is false if one is measured in different units.
In a method comparison the two axes are usually the same quantity in the same units, which is precisely when λ = 1 is defensible.
The suite checks this case against the eigenvector of the covariance matrix, an unrelated derivation of the same line, and the two agree to machine precision on 200 fits.
Deming or Passing-Bablok
Both fit a line with error on both axes. They differ in what else they assume, and the choice is usually decided by the data rather than by preference.
Deming assumes the errors are normal with a known variance ratio. Given that, it is efficient — it extracts more from the same data than a rank-based method.
Passing-Bablok assumes almost nothing and needs no λ at all, at the cost of wider intervals.
One outlier is what usually decides it. Deming is a least-squares method under the surface and moves with an extreme point; Passing-Bablok barely notices.
The practical rule: plot the data first. Clean, normal-looking scatter with a known λ favours Deming; anything else favours the rank-based fit.
Why the intervals are jackknifed
Closed-form standard errors exist for Deming regression and they are fragile in the cases that matter.
They assume λ is known exactly, which it never is, and they assume normal errors, which a method comparison rarely checks.
The jackknife refits the line n times, leaving out one pair each time, and takes the spread of those refits.
It needs no distributional assumption and it degrades honestly. A design where one point carries the fit produces a visibly wide interval rather than a narrow one built on a formula that does not apply.
It is not free: the jackknife is known to be slightly optimistic for this fit at small n, so an interval from fifteen pairs should be read as indicative.
Reporting a Deming fit
Four items, and the first is the one that makes the result reproducible at all.
Give λ and say where it came from. “λ = 1, assumed equal imprecision” is honest; “Deming regression” alone is not enough to recompute anything.
Give both slope and intercept with intervals. A slope near 1 with an intercept far from 0 is a constant offset; a slope away from 1 is a proportional difference. They mean different things.
Give n and the range of the measurements. A slope estimated over a narrow range extrapolates badly, and method comparisons are often run on samples spanning only part of the clinical range.
And say whether you checked for outliers. Deming is a least-squares method and one extreme pair can move it.
Method. The slope comes from the standard closed form, and the two limits it sits between — ordinary least squares and the regression run the other way — are computed in the same pass and printed, because a Deming slope outside that range would be an arithmetic error rather than a finding. The suite asserts all three relationships on 200 generated fits: that the Deming slope always lies between the two ordinary regressions, that it converges to each of them as λ grows and shrinks, and that swapping the two methods inverts it exactly — the symmetry least squares fails. At λ = 1 the fit is total least squares, and the suite checks it against the principal eigenvector of the covariance matrix, a derivation with nothing in common with the closed form used here. Confidence intervals are jackknifed rather than taken from a closed-form standard error, since the closed forms assume λ is known exactly and that the errors are normal; the jackknife needs neither and degrades visibly when one pair carries the fit. That engine is verified on every change against 103 assertions. The count and the per-case breakdown are published on the formula verification page.
Related calculators
Where this goes next:
Passing-BablokRobust method-comparison regression with rank-based intervals, the symmetry shift reported, and the pairwise-slope distribution shown.
Bland-AltmanLimits of agreement with confidence intervals on the limits themselves, a proportional-bias test and the correlation printed beside them for contrast.
Theil-SenThe median-of-slopes estimator with a distribution-free interval, least squares beside it, and a leave-one-out table naming what each fit depends on.
Linear RegressionThe least-squares line with r and r² — and the regression of x on y beside it, because those are two different lines rather than one line rearranged.
Concordance CorrelationLin's concordance correlation with its exact decomposition into precision and accuracy, the scale and location shifts separated, and a bounded interval.
Correlation CoefficientReports Pearson, Spearman and Kendall together with the scatter plot, and ships Anscombe's quartet built in — four datasets with an identical r of 0.816 that Spearman tells apart.
An educational tool. Deming regression needs λ — the ratio of the two error variances — and that ratio cannot be estimated from the paired data; a wrong λ moves the slope. It is also a least-squares method underneath, so a single extreme pair can move the fit, and its jackknife intervals are slightly optimistic below about twenty pairs.
Launched errors-in-variables regression with the error-variance ratio as a visible control rather than a hidden default.
Printed ordinary least squares and the inverse regression as the two limits the Deming slope lies between, and asserted that ordering on 200 generated fits.
Checked the lambda = 1 case against the principal eigenvector of the covariance matrix, a derivation with nothing in common with the closed form used.
Used jackknife intervals rather than closed-form standard errors, which assume lambda is known exactly.
Added a table of the fitted slope across five lambda values, so the sensitivity to the assumption is visible.
Add this calculator to your site
Responsive embed — and private: nothing your visitors type leaves their browser.