The Complete SPRLIB & ANNLIB

mahal_dataset

- compute the Mahalanobis coefficients for a class (LOCAL)

SYNOPSIS

int mahal_dataset (lset, class, W2, W1, b, n)

ARGUMENTS

DATASET *lset The dataset with which the coefficients are determined.
int class The desired class for which the coefficients are determined.
double **W2 The quadratic coefficient, a matrix of size [1..n][1..n].
double *W1 The linear component, a vector of size [1..n].
double b The constant coefficient.
int n The number of features.

RETURNS

The coefficients which can be used to determine the mahalanobis distance of a pattern to class class. And TRUE if an error occured and FALSE otherwise.

FUNCTION

mahal_dataset is used to calculate the coefficients needed to determine the Mahalanobis distance of a pattern to a class. The coefficients are determined using the dataset lset given the desired class class. It returns the coefficients W2, W1 and b which are needed to compute the distance to the class.

NOTE

The variable W1 is in vector format and W2 is in matrix format.

SEE ALSO

mahal_multiclass_dataset

This document was generated using api2html on Thu Mar 5 09:00:00 MET DST 1998