class.ind.RdGenerates a class indicator function from a given factor.
class.ind(cl)a matrix which is zero except for the column corresponding to the class.
Venables, W. N. and Ripley, B. D. (2002) Modern Applied Statistics with S. Fourth edition. Springer.