Fisher Discriminant Analysis

​
θ
The 30 round points are data. The 15 red points were generated from a normal distribution with mean
{1.2,0}
, the 15 blue ones with mean
{0,1.2}
, and in both cases the covariance matrix was the identity matrix. The problem is to classify or predict the color using the inputs
x
1
and
x
2
.
Fisher linear discriminant analysis determines a canonical direction for which the data is most separated when projected on a line in this direction. The solid gray line shows the canonical direction.
The squares are projected points on a line inclined at the angle
θ
with respect to the origin. When
θ
is adjusted so the projected points are aligned with the gray line, the points are maximally separated in the sense that the ratio of between-classes variances to within-classes variance is maximized.
A point is predicted as red or blue according to whether its projection on the canonical direction lies closest to the projected mean of the red or blue data points.

Details

The canonical direction is given by
v=
argmax
a∈
2
ℜ
′
a
Σ
b
a
′
a
Σ
w
a
,
where
Σ
b
and
Σ
w
are the between- and within-classes covariance matrices. Hastie, Tibshirani and Friedman (2009, §4.3.3)[3] show that
v
is given by the largest eigenvalue of
-1
Σ
w
Σ
b
.
The more general case where the number of inputs
p
is greater than 2 is also considered in[3], but the basic principle of finding the canonical direction is the same. In our illustrative problem we have
p=2
inputs as well as
K=2
classes. In general, there are
K-1
orthogonal canonical directions with the first canonical direction as defined above. Sometimes, as in[2], it is sufficient just to use just the first canonical component. For extensions, see[3].
[1] Wikipedia, "Linear Discriminant Analysis."
[2] R. A. Fisher, "The Use of Multiple Measurements in Taxonomic Problems," Annals of Eugenics, 7, 1936 pp. 179–188.
[3] T. Hastie, R. Tibshirani, and J. Friedman, The Elements of Statistical Learning: Data Mining, Inference, and Prediction, 2nd ed., New York: Springer, 2009.

External Links

Principal Components

Permanent Citation

Ian McLeod
​
​"Fisher Discriminant Analysis"​
​http://demonstrations.wolfram.com/FisherDiscriminantAnalysis/​
​Wolfram Demonstrations Project​
​Published: March 7, 2011