Basic Statistics Michael Koch

advertisement
Basic Statistics
Michael Koch
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Statistics
 Are a tool to answer questions:
 How accurate is the analyses?
 How many analyses do I have to make to
overcome problems of inhomogeneity or
imprecision?
 Does the product meet the specification?
 With what confidence is the limit
exceeded?
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Analytical results vary
 Because of unavoidable deviation during
measurement
 Because of inhomogeneity between the
subsamples
 It is very important to differentiate between
these two cases
 Because the measures to be taken can be
different
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Variations
 Are always present
 If there seems to be
none, the resolution
is not high enough
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
322
322
322
322
322
322
322
322
322
322
322
322
322
322
322
322
322
322
322
322
322,3
322,5
322,3
322,2
321,7
321,8
321,7
322,2
321,6
322,4
322,4
321,5
322,4
322,1
322,2
322,5
321,7
321,8
321,9
322,4
322,29
322,49
322,28
322,17
321,67
321,76
321,75
322,17
321,58
322,36
322,40
321,53
322,42
322,05
322,16
322,47
321,73
321,76
321,85
322,41
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Histogram
 For the description of the variability
 Divide range of possible measurements
into a number of groups
 Count observations in each group
 Draw a boxplot of the frequencies
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Histogram
frequency
20
18
16
14
12
10
8
6
4
2
0
45,75 46,25 46,75 47,25 47,75 48,25 48,75 49,25 49,75 50,25 50,75
mg/g
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Distribution
 If the number of values rises and the
groups have a smaller range, the
histogramm changes into a distribution
curve
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Cumulative Distribution
 The cumulative distribution is obtained
by summing up all frequencies
 It can be used to find the proportion of
values that fall above or below a certain
value
 For distributions (or histograms) with a
maximum, the cumulative distribution
curve shows the typical S-shape
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Cumulative Distribution
cumulative frequency [%]
100
80
60
40
20
0
45,75
46,75
47,75
48,75
49,75
50,75
mg/g
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Population –
Sample
 It is important to know, whether all data (the
population) or only a subset (a sample) are
known.
Sample
Population
A selection of 1000
inhabitants of a town
All inhabitants of
a town
Any number of
measurements of
copper in a soil
Not possible
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Distribution Descriptives
 The data distribution can be described
with four characteristics:




Measures of location
Measures of dispersion
Skewness
Kurtosis
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Location –
Arithmetic Mean
 Best estimation of the population mean
µ for random samples from a population
n
x
x
i
i 1
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
n
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Location –
Median
 Sort data by value
 Median is the central value of this series
 The median is robust, i.e. it is not
affected by extreme values or outliers
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Location –
Mode
 The most frequent value
 Large number of values necessary
 It is possible to have two or more
modes
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Location –
Other Means




Geometric mean
Harmonic Mean
Robust Mean (e.g. Huber mean)
...
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Dispersion –
Variance of a population
 The mean of the squares of the
deviations of the individual values from
the population mean.
n
 
2
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
 (x
i 1
i
 )
2
n
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Dispersion –
Variance of a sample
 Variance of population with (n-1)
replacing n and the arithmetic mean of
the data (estimated mean) replacing the
population mean µ
n
s 
2
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
 (x
i 1
i
 x)
2
n1
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Dispersion –
standard deviation
 The positive square root of the variance
Population
Sample
n
n
 

i 1
( xi   ) 2
n
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
s

i 1
( xi  x ) 2
n1
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Dispersion –
standard deviation of the mean
 possible means of a data set are more
closely clustered than the data
sdm 
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)

where n is the number of
measurements for the mean
n
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Dispersion –
relative standard deviation
 measure of the spread of data
compared with the mean
s
RSD 
x
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Skewness
 The skewness of a distribution
represents the degree of symmetry
 Analytical data close to the detection
limit often are skewed because
negative concentrations are not
possible
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Kurtosis
 The peakedness of a distribution.
 Flat  platykurtic
 Very peaked  leptokurtic
 In between  mesokurtic
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Normal distribution - I
 First studied in the 18th century by Carl
Friedrich Gauss
 He found that the distribution of errors could
be closely approximated by a curve called the
„normal curve of errors“
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Normal distribution - II
 bell shaped
 completely determined by µ and σ
1
y
e
 2
( x  ) 2
2 2
µ
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Normal distribution – important
properties





the curve is symmetrical about µ
the greater the value of σ the greater the spread of the curve
approximately 68% (68,27%) of the data lies within µ±1σ
approximately 95 % (95,45%) of the data lies within µ±2σ
approximately 99,7 % (99,73%) of the data lies within µ±3σ
µ
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Normal distribution –
a useful model
 With the mean and the standard
deviation area under the curve can be
defined
 These areas can be interpreted as
proportions of observations falling within
these ranges defined by µ and σ
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
One-tailed / two-tailed questions
 One-tailed
 Two-tailed
 e.g. a limit for the
specification of a
product
 It is only of interest,
whether a certain
limit is exceeded or
not
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
 e.g. the analysis of a
reference material
 we want to know,
whether a measured
value lies within or
outside the certified
value ± a certain
range
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
One-sided probabilities
One-sided Probabilities
Less than µ + k, P(<)
Greater than µ + k, P(>)
k
1
1.64
1.96
2
3
µ-k
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
µ
P(<)
0.841
0.950
0.975
0.977
0.998
P(>)
0.159
0.050
0.025
0.023
0.002
µ+k
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Two-sided probabilities
Two-sided Probabilities
Area within the range µ ± k, P(in)
Area outside the range µ ± k, P(out)
k
1
1.64
1.96
2
3
µ-k
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
µ
P(in)
0.683
0.900
0.950
0.954
0.997
P(out)
0.317
0.100
0.050
0.046
0.003
µ+k
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Population / sample
 small random samples of results from a
normal distribution may not look normal at first
sight
 e.g. samples from a population of 996 data
sample
of
100
249
values
sample
of498
10 values
20
50
all 996
values
999988868
11110000
66646
11111111
44424
11112222
22202
1
1
13323
0080
111333
8868
111444
6646
1
1
1555
4424
9998900080
88882202
2
777774424
4
666666646
6
000
555558868
8
Sample size mean
555450080
0
73
40
10
5
20
35
6
2,5
8
4
30
5
152
25
4
36
20
1,5
10
3
24
15
21
10
5
12
0,5
15
4444222
2
frequency
frequency
frequency
12
8
3,5
6
25
45
Population: µ=100, σ=19,75
value
value
value
value
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
s
10
99,6
20,48
20
101,8
18,14
50
97,76
19,13
100
96,52
20,14
249
98,63
20,10
498
97,81
20,49
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Confidence limits / intervals
 The confidence limits describe the
range within which we expect with given
confidence the true value to lie.
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Confidence limits for the
population mean
 If the population standard deviation σ
and the estimated mean are known:
 CL for the population mean, estimated
from n measurements on a confidence
level of 95%
CL  x  196
. 
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)

n
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Confidence limits for the
population mean
 If the standard deviation has to be
estimated from a sample standard
deviation s (this is normally the case):
 Additional uncertainty  use of Student
t distribution
Where t is the two-tailed
s
CL  x  t 
n
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
tabulated value for (n-1)
degrees of freedom and the
requested confidence limit
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
t-values
Critical values for the Student t-Test
d.o.f. \ 1T
d.o.f. \ 2T
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
60%
20%
0,3249
0,2887
0,2767
0,2707
0,2672
0,2648
0,2632
0,2619
0,2610
0,2602
0,2596
0,2590
0,2586
0,2582
0,2579
0,2576
0,2573
0,2571
0,2569
0,2567
75%
50%
1,000
0,8165
0,7649
0,7407
0,7267
0,7176
0,7111
0,7064
0,7027
0,6998
0,6974
0,6955
0,6938
0,6924
0,6912
0,6901
0,6892
0,6884
0,6876
0,6870
80%
60%
1,376
1,061
0,9785
0,9410
0,9195
0,9057
0,8960
0,8889
0,8834
0,8791
0,8755
0,8726
0,8702
0,8681
0,8662
0,8647
0,8633
0,8620
0,8610
0,8600
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
85%
70%
1,963
1,386
1,250
1,190
1,156
1,134
1,119
1,108
1,100
1,093
1,088
1,083
1,079
1,079
1,074
1,071
1,069
1,067
1,066
1,064
90%
80%
3,078
1,886
1,638
1,533
1,476
1,440
1,415
1,397
1,383
1,372
1,363
1,356
1,350
1,345
1,341
1,337
1,333
1,330
1,328
1,325
95%
90%
6,314
2,920
2,353
2,132
2,015
1,943
1,895
1,860
1,833
1,812
1,796
1,782
1,771
1,761
1,753
1,746
1,740
1,734
1,729
1,725
97,50%
95%
12,71
4,303
3,182
2,776
2,571
2,447
2,365
2,306
2,262
2,228
2,201
2,179
2,160
2,145
2,131
2,120
2,110
2,201
2,093
2,086
99%
98%
31,82
6,965
4,541
3,747
3,365
3,143
2,998
2,896
2,821
2,764
2,718
2,681
2,650
2,624
2,602
2,583
2,567
2,552
2,539
2,528
99,50%
99%
63,66
9,925
5,841
4,604
4,032
3,707
3,499
3,355
3,250
3,169
3,106
3,055
3,012
2,977
2,947
2,921
2,898
2,878
2,861
2,845
99,90%
99,80%
318,3
22,33
10,21
7,173
5,893
5,208
4,785
4,501
4,297
4,144
4,025
3,930
3,852
3,787
3,733
3,686
3,646
3,610
3,579
3,552
99,95%
99,90%
636,6
31,60
12,94
8,610
6,869
5,959
5,408
5,041
4,781
4,587
4,437
4,318
4,221
4,140
4,073
4,015
3,965
3,922
3,883
3,850
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Confidence limits –
depending on n
 Confidence Limits are strongly dependent on
the number of measurements
CLn=1
CLn=3
CLn=10
µ
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Trueness – Precision – Accuracy - Error
 Trueness
 the closeness of agreement between the true value
and the sample mean
 Precision
 the degree of agreement between the results of
repeated measurements
 Accuracy
 the sum of both, trueness and precision
 Error
 the difference between one measurement and the
true value
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Improving trueness
Linkage
Improving
accuracy
Error
Improving precision
from: LGC, vamstat II
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Significance Testing - ?
 Typical Situation:
 We have analyzed a reference material
and we want to know, if the bias between
the mean of measurements and the
certified value of a reference material is
„significant“ or just due to random errors.
 This is a typical task for significance
testing
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Significance testing
 a decision is made
 about a population
 based on observations made from a sample of the
population
 on a certain level of confidence
 there can never be any guarantee that the
decision is absolutely correct
 on a 95% confidence level there is a
probability of 5% that the decision is wrong
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Before significance testing
 inspect a graphical display of the data before
using any statistics
 are there any data that are not suitable?
 is a significance test really necessary?
 compare the statistical result with a
commonsense visual appraisal
 a difference may be statistically significant,
but not of any importance, because it is small
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
The most important
thing in statistics
No blind use
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
The stages of significance
testing - I
 Null hypothesis
 a statement about the population, e.g.:
There is no bias (µ = xtrue)
 Alternative hypothesis H1
 the opposite of the null hypothesis, e.g.:
there is a bias (µ ≠ xtrue)
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
The stages of significance
testing - II
 Critical value
 the tabulated value of the test statistics,
generally at the 95% confidence level.
 If the calculated value is greater than the
tabulated value than the test result
indicates a significant difference
 Evaluation of the test statistics
 Decisions and conclusions
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Significance test example –
the question
 Is the bias between the mean of
measurements and the certified value of
a reference material significant or just
due to random errors?
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Significance test example –
graphical explanation
95% confidence interval for
the population mean µ
significant
 the reference value is outside the 95%
confidence limits of the data set
 the bias is unlikely to result from
random variations in the results
 the bias is significant
x ref
not significant
x
95% confidence interval for
the population mean µ
 the reference value is inside the 95%
confidence limits of the data set
 the bias is likely to result from random
variations in the results
x ref x
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
 the bias is not significant
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Significance test example calculation
 The Null hypothesis
 we assume there is no bias: x=xref
 Calculation of confidence limits

ts
ts
x
   x
n
n
 With the Null hypothesis

ts
ts
x
 xref  x 
n
n
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
or
t critical  t observed 
x  xref
s
n
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
t-values
Critical values for the Student t-Test
d.o.f. \ 1T
d.o.f. \ 2T
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
60%
20%
0,3249
0,2887
0,2767
0,2707
0,2672
0,2648
0,2632
0,2619
0,2610
0,2602
0,2596
0,2590
0,2586
0,2582
0,2579
0,2576
0,2573
0,2571
0,2569
0,2567
75%
50%
1,000
0,8165
0,7649
0,7407
0,7267
0,7176
0,7111
0,7064
0,7027
0,6998
0,6974
0,6955
0,6938
0,6924
0,6912
0,6901
0,6892
0,6884
0,6876
0,6870
80%
60%
1,376
1,061
0,9785
0,9410
0,9195
0,9057
0,8960
0,8889
0,8834
0,8791
0,8755
0,8726
0,8702
0,8681
0,8662
0,8647
0,8633
0,8620
0,8610
0,8600
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
85%
70%
1,963
1,386
1,250
1,190
1,156
1,134
1,119
1,108
1,100
1,093
1,088
1,083
1,079
1,079
1,074
1,071
1,069
1,067
1,066
1,064
90%
80%
3,078
1,886
1,638
1,533
1,476
1,440
1,415
1,397
1,383
1,372
1,363
1,356
1,350
1,345
1,341
1,337
1,333
1,330
1,328
1,325
95%
90%
6,314
2,920
2,353
2,132
2,015
1,943
1,895
1,860
1,833
1,812
1,796
1,782
1,771
1,761
1,753
1,746
1,740
1,734
1,729
1,725
97,50%
95%
12,71
4,303
3,182
2,776
2,571
2,447
2,365
2,306
2,262
2,228
2,201
2,179
2,160
2,145
2,131
2,120
2,110
2,201
2,093
2,086
99%
98%
31,82
6,965
4,541
3,747
3,365
3,143
2,998
2,896
2,821
2,764
2,718
2,681
2,650
2,624
2,602
2,583
2,567
2,552
2,539
2,528
99,50%
99%
63,66
9,925
5,841
4,604
4,032
3,707
3,499
3,355
3,250
3,169
3,106
3,055
3,012
2,977
2,947
2,921
2,898
2,878
2,861
2,845
99,90%
99,80%
318,3
22,33
10,21
7,173
5,893
5,208
4,785
4,501
4,297
4,144
4,025
3,930
3,852
3,787
3,733
3,686
3,646
3,610
3,579
3,552
99,95%
99,90%
636,6
31,60
12,94
8,610
6,869
5,959
5,408
5,041
4,781
4,587
4,437
4,318
4,221
4,140
4,073
4,015
3,965
3,922
3,883
3,850
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Significance test example –
conclusions I
 If we find tcritical > tobserved
 conforming to our Null hypothesis
 we can say:




we cannot reject the Null hypothesis
we accept the Null hypothesis
we find no significant bias at the 95% level
we find no measurable bias (under the given
experimental conditions)
 but not: there is no bias
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Significance test example –
conclusions II
 If we find tcritical < tobserved
 not conforming to our Null hypothesis
 we can say:
 we reject the null hypothesis
 we find significant bias at the 95% level
 but not: there is a bias, because there is
roughly a 5% chance of rejecting the Null
hypothesis when it is true.
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
One-sample t-test
 This test compares the mean of analytical
results with a stated value
 The question may be two-tailed
 as in the previous example
 or one-tailed
 e.g.: is the copper content of an alloy below the
specification?
 for one-tailed questions other t-values are used
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
t-values
Critical values for the Student t-Test
d.o.f. \ 1T
d.o.f. \ 2T
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
60%
20%
0,3249
0,2887
0,2767
0,2707
0,2672
0,2648
0,2632
0,2619
0,2610
0,2602
0,2596
0,2590
0,2586
0,2582
0,2579
0,2576
0,2573
0,2571
0,2569
0,2567
75%
50%
1,000
0,8165
0,7649
0,7407
0,7267
0,7176
0,7111
0,7064
0,7027
0,6998
0,6974
0,6955
0,6938
0,6924
0,6912
0,6901
0,6892
0,6884
0,6876
0,6870
80%
60%
1,376
1,061
0,9785
0,9410
0,9195
0,9057
0,8960
0,8889
0,8834
0,8791
0,8755
0,8726
0,8702
0,8681
0,8662
0,8647
0,8633
0,8620
0,8610
0,8600
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
85%
70%
1,963
1,386
1,250
1,190
1,156
1,134
1,119
1,108
1,100
1,093
1,088
1,083
1,079
1,079
1,074
1,071
1,069
1,067
1,066
1,064
90%
80%
3,078
1,886
1,638
1,533
1,476
1,440
1,415
1,397
1,383
1,372
1,363
1,356
1,350
1,345
1,341
1,337
1,333
1,330
1,328
1,325
95%
90%
6,314
2,920
2,353
2,132
2,015
1,943
1,895
1,860
1,833
1,812
1,796
1,782
1,771
1,761
1,753
1,746
1,740
1,734
1,729
1,725
97,50%
95%
12,71
4,303
3,182
2,776
2,571
2,447
2,365
2,306
2,262
2,228
2,201
2,179
2,160
2,145
2,131
2,120
2,110
2,201
2,093
2,086
99%
98%
31,82
6,965
4,541
3,747
3,365
3,143
2,998
2,896
2,821
2,764
2,718
2,681
2,650
2,624
2,602
2,583
2,567
2,552
2,539
2,528
99,50%
99%
63,66
9,925
5,841
4,604
4,032
3,707
3,499
3,355
3,250
3,169
3,106
3,055
3,012
2,977
2,947
2,921
2,898
2,878
2,861
2,845
99,90%
99,80%
318,3
22,33
10,21
7,173
5,893
5,208
4,785
4,501
4,297
4,144
4,025
3,930
3,852
3,787
3,733
3,686
3,646
3,610
3,579
3,552
99,95%
99,90%
636,6
31,60
12,94
8,610
6,869
5,959
5,408
5,041
4,781
4,587
4,437
4,318
4,221
4,140
4,073
4,015
3,965
3,922
3,883
3,850
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Two-sample t-test
 This test compares two independent
sets of data (analytical results)
 The question may be two-tailed or onetailed as well
 two-tailed: are the results of two methods
significantly different
 one-tailed: are the results of method A
significantly lower than the results of
method B
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
two-sample t-test – t-value
 The formula for the calculation of the tvalue is somewhat more complex:
tobserved 
( x1  x 2 )
 1 1   s12 n1  1  s22 n2  1 
    

n1  n2  2 
 n1 n2  
 The degree of freedom for the tabulated
value tcritical is
d.o.f = n1+n2-2
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
two-sample t-test - validity
 The two-sample t-test is valid only if
there is no significant difference
between the both standard deviations s1
and s2.
 This can (and should) be tested with the
F-test
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
F-test
 The F-test is a method of testing
whether two independent estimates of
variance are significantly different.
 The F-value is calculated according to
Fobserved=sA2/sB2, with sA2 > sB2
 The critical value of F depends on the
degrees of freedom dofA=nA-1 and
dofB=nB-1 and can be taken from a table
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
F-values
nB=10
degrees of freedom for denumerator (B)
F statistics
for P=0.05
1
2
degrees of freedom for numerator (A)
3
4
5
6
7
8
9
10
1 647,79 799,50 864,16 899,58 921,85 937,11 948,22 956,66 963,29 968,63
2
38,51
39,00
39,17
39,25
39,30
39,33
39,36
39,37
39,39
39,40
3
17,44
16,04
15,44
15,10
14,89
14,74
14,62
14,54
14,47
14,42
4
12,22
10,65
9,98
9,61
9,36
9,20
9,07
8,98
8,91
8,84
5
10,01
8,43
7,76
7,39
7,15
6,98
6,85
6,76
6,68
6,62
6
8,81
7,26
6,60
6,23
5,99
5,82
5,70
5,60
5,52
5,46
7
8,07
6,54
5,89
5,52
5,29
5,12
5,00
4,90
4,82
4,76
8
7,57
6,06
5,42
5,05
4,82
4,65
4,53
4,43
4,36
4,30
9
7,21
5,72
5,08
4,72
4,48
4,32
4,20
4,10
4,03
3,96
10
6,94
5,46
4,83
4,47
4,24
4,07
3,95
3,86
3,78
3,72
nA=10
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
F-test - decision
 If Fobserved < Fcritical than the variances
sA2 and sB2 are not significantly different
 on the chosen confidence level
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Paired t-test
 Two different methods are applied for
measuring different samples
3
Two-sample t-test is
inappropriate, because
differences between samples
ar much greater than a bias
between the two methods
Method A
Method B
2,5
2
1,5
 paired t-test
1
0,5
0
sample 1
sample 3
sample 2
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
sample 5
sample 4
sample 6
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Paired t-test - principle
 The differences between both methods
are calculated
 A one-sample t-test is applied on the
differences to decide whether the mean
difference is significantly different from
zero.
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Paired t-test – test statistics
 The t-value is calculated according to:
tobserved 
x diff
sdiff
n
 The critical t-value is taken from the ttable for the desired confidence level
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Statistics
 There are many statistical tools for the
analyst to interpret analytical data
 Statistics are not a „cure-all“ that can
answer all questions
 If the analyst uses statistics with a
commonsense, this is a powerful tool to
help him to answer his customers or his
own questions.
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Recommended literature and
training software
 LGC, VAMSTAT II, Statistics Training for Valid
Analytical Measurements. CD-ROM, Laboratory of
the Government Chemist, Teddington 2000.
 H. Lohninger: Teach/Me - Data Analysis. Multimedia
teachware. Springer-Verlag 1999.
 J.C. Miller and J.N. Miller: Statistics for Analytical
Chemistry. Ellis Horwood Ltd., Chicester 1988
 T.J. Farrant: Practical Statistics for the Analytical
Scientist – a Bench Guide. Royal Society of
Chemistry for the Laboratory of the Government
Chemist (LGC), Teddington 1997
Koch, M.: Basic Statistics
In: Wenclawiak, Koch, Hadjicostas (eds.)
© Springer-Verlag Berlin Heidelberg 2003
Quality Assurance in Analytical Chemistry – Training and Teaching
Download