Download as pdf or txt
Download as pdf or txt
You are on page 1of 20

Testing of Normality

Peter Luk
January 17, 2009
Introduction
The most significant development in financial
mathematics over the past three decades was the
Black-Scholes formula published in 1974 and the
subsequent surge of derivative business around the
world. A strong demand for high caliber
mathematicians has ensued, as the need in the area of
mathematical modelling, particularly in conjunction
with the rapid development of structured financial
products (such as the now famous CDO), has increased
exponentially. This demand is unlikely to subside in
the foreseeable future.
Most of these models, probably over 90% or even
99% of them, are based on a fundamental
assumption that stock prices or interest rates
fluctuate following the normal distribution.
In the wake of the current financial crisis, there has
been a great deal of criticism about the
indiscriminate use of the normal assumption, which
lent people a false sense of security and prompted
people to indulge in unwarranted leveraging. The
following are a few examples.
Professor Eugene Fama in his ground-breaking 1965
paper The Behavior of Stock-Market Prices said
an observation more than five standard deviations
from the mean should be observed about once every
7,000 years. In fact, such observations seem to occur
once every three to four years.
William Poole, former president of Federal Reserve
Bank of St. Louis said in 2005 there are 16 times
more price changes in excess of 3.5 standard
deviations than expected within the normal
distribution. Really large change of 4.5 or more
standard deviations occur only 7 times in a million
under the normal distribution, but there are 11 such
changes in less than 7,000 daily observations.
Wall Street Journal 8/11/2007 Events that Lehmans
computer model only predicted would happen once in
10,000 years happened every day for three days.
Financial Times 8/14/2007 Goldman Sachs revealed the
computer had failed to foresee recent market movements to
such a degree that they labelled them a 25-standard
deviation event something that only happens once every
100,000 years or more.
Professor Nassim Taleb, whose best-selling books Fooled
by Randomness and Black Swan outsold Alan
Greenspan, was interviewed by Fortune 4/3/2008 We
replaced so much common sense with models that work
worse than astrology. Business schools taught financial
theory as a replacement for experience.
It is now obvious that it is highly desirable to make sure that
your normal assumption is justifiable by way of statistical
testing before you do some serious modelling. Introduced
here are four most commonly used testing methods, i.e.,
Anderson-Darling test (A
2
)
Cramr-von Mises test (W
2
)
DAgostinos K
2
test
Jarque-Bera test
Other less used tests including Chi-square test, Kolmogorov
test, Shapiro-Wilk test, Shapiro-Francia test, Lillifors test,
DAgostinos D test, etc. are not explored here.
Notation
We shall use x to represent the sample value, Z the
normalized value and p the conventional p-value as shown
in the following chart.
Anderson-Darling Test
Suppose we have a random sample of size n: x
1
<x
2
<<x
n
, and we want to test if
it comes from a normal population. The method used here is the so-called edf
(empirical distribution function) method, similar to the well-known Kolmogorov
method. The edf is F
e
(x) where:
F
e
(x) = 0, x < x
1
; F
e
(x) = 1, x
n
x
F
e
(x) = i/n , x
i
x x
i+1
, i = 1, 2, n-1
On the other hand, the true distribution function is represented by F
t
(x) and we
want to see how close these two distribution functions are. As an example, we
have the following 4 values.
i 1 2 3 4
x -1 0.5 1 1.5
F
e
(x) 0.25 0.5 0.75 1
Z = F
t
(x) 0.16 0.69 0.84 0.93
The respective F
e
(x) and F
t
(x) are shown in the chart below (in the example here
F
t
(x) is a standard normal distribution curve). If the two distribution functions are
close enough, we can say x comes from a normal distribution. With Kolmogorov
test, we examine the maximum distance between the two. With A-D test,
calculations are made taking into account all the points along the curve.
The Anderson-Darling test statistic for the normal distribution is calculated as:
Where Zs are transformed from Xs as follows.
Let m be the mean of Xs and o
2
be the 2
nd
central moments and
then,
The following formula gives the p-values between 0.5% and 25% .
p = exp(1.2929 5.6972 A
2
)
} 2.25/n n / 75 . 0 1 }{ )] Z (1 ln Z 1][ln [2i n) / 1 ( n { A
2
n
1 i
i 1 n i
2
+ + + =

=
+

1
s o

=
n
n
dy
2 s
1
(x) F Z
2
S
2
2
) ( x
-
t
m y
e

}
= =
t
Cramr-von Mises Test
This test is similar to Anderson-Darling test except that the test statistic is
calculated as:

=
+ + =
n
1 i
2
i
2
0.5/n} }{1 1)/(2n)] (2i Z [ {1/(12n) W
The following gives the p-values between 0.5% and 25%.
p = exp {30.8642 (0.0292 W
2
)}
DAgostinos K
2
Test
Let
3
and
4
be the 3
rd
and 4
th
central moments.
Let b
1
=
3
/ o
3
Note: we are not using the conventional symbol of
b
2
=
4
/ o
4
b
1
is a measure of skewness. For the normal distribution it should equal 0. With
certain transformation of b
1
, we get a statistic T
1
, which is approximately a
standard normal variate. Therefore, if T
1
is too big or too small, well reject the
normal hypothesis.
b
1
9) 7)(n 5)(n 2)(n (n
3) 1)(n 70)(n 27n 3(n

2
+ + +
+ + +
= c
) 1 ( 2 1 V + = c
V)/2 (ln / ) 1 Y Y ln( T
2
1
+ + =
On the other hand, b
2
is a measure of kurtosis. For the normal distribution, it
should equal 3. With certain transformation of b
2
, we get another statistic T
2
,
which is approximately a standard normal variate. Therefore, if T
2
is too big or too
small, well also reject the normal hypothesis.
3) 2)(n 24n(n
5) 3)(n (n 1) (n
}
1 n
1) 3(n
b { g
2
2

+ + +
+

=
2) 12(n
1) - 3)(V 1)(n (n
b Y
1

+ +
=
5) 3)(n 6(n
3) 2)(n n(n

2) n 5 6(n
9) 7)(n (n
j
2
+ +

+
+ +
=
) 4j 1 (2j 8j 6 H
2
+ + + =
2
9H

4) - 2/(H g 1
2/H 1
)
9H
2
(1 T 3
2

+

=
DAgostino combined T
1
and T
2
together to form an omnibus test:
K
2
= T
1
2
+ T
2
2
For n > 100, K
2
can be viewed as a chi-square variable with two degrees of
freedom. For smaller n, we have to test T
1
and T
2
separately .
Jarque-Bera Test
Similar to DAgostinos K
2
, Jarque-Bera test statistic combines b
1
and b
2
to form a
simple omnibus test.
}
4
3) (b
b {
6
n
JB
2
2
2
1

+ =
JB follows approximately chi-square distribution with two degrees of freedom
when n > 2000. For smaller n, the following table can be used.
p n = 10 20 50 100 500 1000 1500
1% 5.70 9.72 12.39 12.49 10.78 10.12 9.84
5% 2.52 3.80 4.59 5.43 5.86 5.92 5.95
10% 1.62 2.34 2.88 3.67 4.33 4.46 4.51
A real life example
Since the subject today is about financial mathematics, the best example will be
to test some stock market price changes.
For this purpose, we choose to test if the following stock market indices for the
years of 2006, 2007 and 2008 respectively followed the normal distribution.
Hong Kong - Hang Seng Index
Japan - Nikkei 225
USA - Standard & Poor 500
UK - FTSE 100
China - Shanghai Composite
It is to be noted that even though individual price changes do not follow normal
distribution, there is a much bigger chance their average will be normally
distributed, due to the tendency of the central limit theorem.
2008 Test Results
p = A
2
W
2
K
2
JB
Hang Seng Index 0.0% 0.0% 0.0% 0.5%
Nikkei 225 0.0% 0.0% 0.0% 0.5%
Standard & Poor 500 0.0% 0.0% 0.0% 0.5%
FTSE 100 0.0% 0.0% 0.0% 0.5%
Shanghai Composite 2.0% 2.7% 0.9% 0.9%
2007 Test Results
p = A
2
W
2
K
2
JB
Hang Seng Index 0.0% 0.0% 2.5% 1.2%
Nikkei 225 0.1% 0.0% 0.0% 0.5%
Standard & Poor 500 0.0% 0.0% 0.0% 0.5%
FTSE 100 0.1% 0.5% 0.0% 0.5%
Shanghai Composite 0.0% 0.0% 0.0% 0.5%
2006 Test Results
p = A
2
W
2
K
2
JB
Hang Seng Index 0.2% 0.1% 0.0% 0.5%
Nikkei 225 2.8% 1.2% 22.7% 15.0%
Standard & Poor 500 0.1% 0.1% 1.6% 0.6%
FTSE 100 0.1% 1.0% 0.0% 0.5%
Shanghai Composite 0.0% 0.0% 0.0% 0.5%
Thank You

You might also like