### PISAKNN

Uses the results of PISAPEAK to discriminate objects into two classes

#### Description:

PISAKNN uses KNN (k nearest neighbours) distribution-free multivariate discrimination to classify objects into two classes. The classes are seeded by supplying two files which contain the indices of objects typical to the class in question ($>$5, approximately equal numbers of each). Each object then propagates its class to the other objects on the basis of which class of the 2$\ast$k nearest neighbours (in the parameter space of the PISAPEAK results) of each of the unclassified objects is most common. This procedure is iterated until all objects are assigned and have a stable class or until a maximum number of iterations is exceeded. The results of the discrimination are written into two output files, one for each class.

#### Usage:

PISAKNN PEAKDATA SEED1 SEED2 K CLASS1 CLASS2 NITER

#### Parameters:

##### CLASS1 = FILENAME (Write)
Name of a file to contain the indices of the objects selected for membership of class 1. [CLASS1.DAT]
##### CLASS2 = FILENAME (Write)
Name of a file to contain the indices of the objects selected for membership of class 2. [CLASS2.DAT]
If ‘true’ then the ellipticities are used in the analysis. If ‘false’ then they are excluded. Using ellipticities may increase the weighting of some (small) round galaxies as stars. [TRUE]
The number of nearest neighbours about the current values which are to be used in classifying an object. The class used is the most frequently encountered in this range of objects. If classes 1 and 2 are equally frequent then the object classification is not changed. [1]
The maximum number of iterations allowed to classify and reclassify objects. [10]
Name of a file containing the results of the PISAPEAK parameter transformation. This file must contain at least five columns which have the values:
• object index
• intensity-peak ratio
• ellipticity
• absolute value of intensity weighted cross moment

in that order. [PISAPEAK.DAT]

Name of a file containing the indices of the objects to seed class1. The file can contain any number of columns but must have the object indices in column one. [SEED1.DAT]