Major topics covered in this chapter
Uncertainty 99 to each, and then combines these components using the rules summarised in
5.10 Weighted regression lines
Weighted regression lines 135 so x-direction errors may be significant. In other cases, the opposite situation occurs, i.e.
the y-direction errors are so small that they become comparable with the x-direction ones. Such data may occur in the use of highly automated flow analysis methods, such as flow injection analysis or high-performance liquid chromatography. The FREML method provides for both y- and x-direction errors. It assumes that the errors in the two directions are normally distributed, but that they may have unequal variances, and it minimises the sums of the squares of both the x- and y-residuals, divided by the corresponding variances. This result cannot be obtained by the simple calculation used when only y-direction errors are considered, but requires an iterative method, which can be implemented using, for example, a macro for Minitab®(see Bibliography).
The method is reversible (i.e. in a method comparison it does not matter which method is plotted on the x-axis and which on the y-axis) and can also be used in weighted regression calculations (see Section 5.10).
136 5: Calibration methods in instrumental analysis: regression and correlation
Signal
Concentration Figure 5.12 The weighting of errors in a regression calculation.
proportional to the corresponding y-direction variance, si2. If the individual points are denoted by (x1, y1), (x2, y2), etc. as usual, and the corresponding standard deviations are s1, s2, etc., then the individual weights, w1, w2, etc., are given by:
(5.10.1)
By using the n divisor in the denominator of the equation the weights have been scaled so that their sum is equal to the number of points on the graph: this simpli-fies the subsequent calculations. The slope and the intercept of the recession line are then given by:
(5.10.2)
and
(5.10.3) In these equations and represent the co-ordinates of the weighted centroid, through which the weighted regression line must pass. These co-ordinates are given
as expected by and yw = a .
i
wiyi>n xw = a
i
wixi>n xw yw
Weighted intercept: aw = yw - bxw Weighted slope: bw =
a
i
wixiyi - nxwyw
ai
wixi2 - nxw2 Weights: wi =
si-2 ai
si-2>n
Example 5.10.1
Calculate the unweighted and weighted regression lines for the following cali-bration data. For each line calculate also the concentrations of test samples with absorbances of 0.100 and 0.600.
Weighted regression lines 137
Application of Eqs (5.4.1) and (5.4.2) shows that the slope and intercept of the unweighted regression line are respectively 0.0725 and 0.0133. The concentra-tions corresponding to absorbances of 0.100 and 0.600 are then found to be 1.20 and 8.09 g ml-1respectively.
The weighted regression line is a little harder to calculate: in the absence of a suitable computer program it is usual to set up a table as follows.
Concentration, µg ml-1 0 2 4 6 8 10
Absorbance 0.009 0.158 0.301 0.472 0.577 0.739
Standard deviation 0.001 0.004 0.010 0.013 0.017 0.022
xi yi si 1/si2 wi wixi wiyi wixiyi wixi2
0 0.009 0.001 106 5.535 0 0.0498 0 0
2 0.158 0.004 62 500 0.346 0.692 0.0547 0.1093 1.384 4 0.301 0.010 10 000 0.055 0.220 0.0166 0.0662 0.880 6 0.472 0.013 5 917 0.033 0.198 0.0156 0.0935 1.188 8 0.577 0.017 3 460 0.019 0.152 0.0110 0.0877 1.216 10 0.739 0.022 2 066 0.011 0.110 0.0081 0.0813 1.100
Sums 1 083943 5.999 1.372 0.1558 0.4380 5.768
These figures give , and . By
Eq. (5.10.2), bwis calculated from
so awis given by 0.0260 (0.0738 0.229) 0.0091.
These values for awand bwcan be used to show that absorbance values of 0.100 and 0.600 correspond to concentrations of 1.23 and 8.01g ml-1respectively.
bw =
0.438 - (6 * 0.229 * 0.026)
5.768 - 36 * (0.229)24 = 0.0738
xw = 1.372>6 = 0.229 yw = 0.1558>6 = 0.0260
Comparison of the results of the unweighted and weighted regression calculations is very instructive. The effects of the weighting process are clear. The weighted cen-troid is much closer to the origin of the graph than the unweighted centroid and the weighting given to the points nearer the origin (particularly to the first point (0, 0.009) which has the smallest error) ensures that the weighted regression line has an intercept very close to this point. The slope and intercept of the weighted line are remarkably similar to those of the unweighted line, however, with the result that the two methods give very similar values for the concentrations of samples hav-ing absorbances of 0.100 and 0.600. This is not simply because in this example the experimental points fit a straight line very well. In practice the weighted and un-weighted regression lines derived from a set of calibration data have similar slopes and intercepts even if the scatter of the points about the line is substantial.
(x, y) (xw, yw)
138 5: Calibration methods in instrumental analysis: regression and correlation
It thus seems on the face of it that weighted regression calculations have little value. They require more information (in the form of estimates of the standard devi-ation at various points on the graph), and are significantly more complex to execute, but they seem to provide results very similar to those obtained from the simpler unweighted regression method. This feeling may indeed account for some of the neglect of weighted regression calculations in practice. But we do not employ regres-sion calculations simply to determine the slope and intercept of the calibration plot and the concentrations of test samples. There is also a need to obtain estimates of the errors or confidence limits of those concentrations, and it is here that the weighted regression method provides much more realistic results. In Section 5.6 we used Eq. (5.6.1) to estimate the standard deviation and hence the confidence limits of a concentration calculated using a single y-value and an unweighted regres-sion line. If we apply this equation to the data in the example above we find that the unweighted confidence limits for the solutions having absorbances of 0.100 and 0.600 are 1.20 ; 0.65 and 8.09 ; 0.63 g ml-1 respectively. As in Example 5.6.1, these confidence intervals are very similar. In the present example, however, such a result is entirely unrealistic. The experimental data show that the errors of the ob-served y-values increase as y itself increases, as expected for a method with a roughly constant relative standard deviation. We would expect that this increase in siwith increasing y would also be reflected in the confidence limits of the determined con-centrations: the confidence limits for the solution with an absorbance of 0.600 should be much greater (i.e. worse) than those for the solution with an absorbance of 0.100.
In weighted recession calculations, the standard deviation of a predicted concen-tration is given by
(5.10.4)
In this equation, s(y/x)wis given by:
(5.10.5)
and w0is a weighting appropriate to the value of y0. Equations (5.10.4) and (5.10.5) are clearly similar in form to Eqs (5.6.1) and (5.5.1). Equation (5.10.4) confirms that points close to the origin, where the weights are highest, and points near the cen-troid, where (y0 ) is small, will have the narrowest confidence limits (Fig. 5.13).
The major difference between Eqs (5.6.1) and (5.10.4) is the term 1/w0in the latter.
Since w0falls significantly as y increases, this term ensures that the confidence lim-its increase with increasing y0, as we expect.
yw
s(y/x)w = L
ai
wi(yi - yNi)2
n - 2 M
1/2
sx0w = s(y>x)w
b L
1 w0 + 1
n +
(y0 - yw)2 b2a a
i
wix2i - nx2wb M
1>2
(sx0)
Weighted regression lines 139
Applying Eq. (5.10.4) to the above example above we find that the test samples with absorbance of 0.100 and 0.600 have confidence limits for the calculated con-centrations of 1.23 ; 0.12 and 8.01 ; 0.72 g ml-1 respectively: these confidence intervals are, as expected, proportional in size to the observed absorbances of the two solutions. The confidence interval for the less concentrated of the two samples is much smaller than in the unweighted regression calculation. By contrast the con-fidence limits for the higher of the two concentrations are quite similar in the un-weighted and un-weighted calculations. This emphasises the particular importance of using weighted regression when the results of interest include those at low concen-trations. Similarly detection limits may be more realistically assessed using the inter-cept and standard deviation obtained from a weighted regression graph. All these results accord much more closely with the reality of such a calibration experiment than do the results of the unweighted regression calculation.
Weighted regression calculations can also be applied in standard additions experi-ments. The equation for the standard deviation of a concentration obtained from a weighted standard additions calibration graph is:
(5.10.6)
In addition, weighted regression methods may be essential when a straight line graph is obtained by algebraic transformations of an intrinsically curved plot (see below, Section 5.13). Computer programs for weighted regression calculations are available, mainly through the more advanced statistical software products, and this should encourage the more widespread use of this method.
sxew = s(y>x)w
b J 1 a
i
wi +
y2w b2
A
ai
wix2i - a
i
nx2w
B
K1/2
Signal
Concentration (x–w,y–w)
Figure 5.13 General form of the confidence limits for a concentration determined using a weighted regression line.
140 5: Calibration methods in instrumental analysis: regression and correlation