The Complete SPRLIB & ANNLIB

samann_scale_dataset

- scale a dataset to make it suitable for SAMANN backpropagation training

SYNOPSIS

int samann_scale_dataset (set, dim)

ARGUMENTS

DATASET *set The DATASET to be scaled.
int dim The dimension the Sammon map should have, i.e. the number of outputs of the network to be trained.

RETURNS

TRUE if an error was detected, FALSE if no error was detected.

FUNCTION

This function normalizes a dataset so that the maximum distance between two samples' input vectors is equal to the maximum distance in the map. Since a network using sigmoid transfer functions can only have outputs in the range [0, 1], the maximum distance between two output vectors is the square root of dim. Therefore, the maximum distance max between two input vectors a and b is found and all sample inputs are scaled by multiplying by max/dim. Finally, the inputs are scaled to fall in the range [0.25, 0.75]. The constant with which the dataset is scaled is printed to stdout.

SEE ALSO

samann_init

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