Statistics Toolbox
  Go to function:
    Search    Help Desk 
classify    Examples   See Also

Linear discriminant analysis.

Syntax

Description

class = classify(sample,training,group) assigns each row of the data in sample into one of the groups that the training set, training, is already divided into. sample and training must have the same number of columns.

The vector group contains integers, from one to the number of groups, that identify which group each row of the training set belongs. group and training must have the same number of rows.

The function returns class, a vector with the same number of rows as sample. Each element of class identifies the group to which the corresponding element of sample has been assigned. The classify function determines into which group each row in sample belongs by computing the Mahalanobis distance of each row in sample to each row in training.

Example

See Also



[ Previous | Help Desk | Next ]