public class LVQ2_1 extends LVQ2
DEFAULT_WINDOW_WIDTH, windowLowerBound, windowWidthalpha_0, ALPHA_DEFAULT_VALUE, chosenRandomIndex, IALPHA, randomIndexesinitial, initialset, iterations, numberOfPrototypesGeneratedalgorithmName, generatedDataSet, SEED, seedDefaultValueList, trainingDataSet| Constructor and Description |
|---|
LVQ2_1(PrototypeSet T,
int iterations,
double pcNprot,
double alpha_0,
double windowWidth)
Construct an LVQ2.1 algorithm.
|
LVQ2_1(PrototypeSet T,
int iterations,
int n_prot,
double alpha_0,
double windowWidth)
Construct an LVQ2.1 algorithm.
|
LVQ2_1(PrototypeSet T,
Parameters parameters)
Construct an LVQ2.1 algorithm.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
correct(Prototype i,
PrototypeSet tData)
Corrects a prototype of a set.
|
protected void |
hardCorrect(Prototype i,
PrototypeSet tData)
Corrects a prototype of a set.
|
static void |
main(java.lang.String[] args)
General main for all the prototoype generators
Arguments:
0: Filename with the training data set to be condensed.
1: Filename wich will contain the test data set
3: k Number of neighbors used in the KNN function
|
extract, initDataSet, initDataSetRandomMode, penalize, rewardreduceSetabsoluteAccuracy, absoluteAccuracyAndError, absoluteAccuracyKNN, accuracy, accuracy2, desordenar_vector_sin, desordenar_vector, execute, generateReducedDataSet, getResultingAccuracy, getResultingAccuracy, getResults, getResultsOfAccuracy, getResultsOfAccuracy, getSeed, getSetSizeFromPercentage, getSetSizeFromPercentage, getTime, inic_vector_sin, inic_vector, saveResultsOfAccuracyIn, saveResultsOfAccuracyIn, selecRandomSet, setSeed, showResultsOfAccuracy, showResultsOfAccuracypublic LVQ2_1(PrototypeSet T, int iterations, int n_prot, double alpha_0, double windowWidth)
T - training data set.iterations - Number of iterations to be performed.n_prot - Number of prototypes to be returned.alpha_0 - Alpha constant of the algorithm.windowWidth - Window width parameter.public LVQ2_1(PrototypeSet T, int iterations, double pcNprot, double alpha_0, double windowWidth)
T - training data set.iterations - Number of iterations to be performed.pcNprot - Size of reduced set as percentage of training size.alpha_0 - Alpha constant of the algorithm.windowWidth - Window width parameter.public LVQ2_1(PrototypeSet T, Parameters parameters)
T - training data set.parameters - Parameters of the algorithms.protected void hardCorrect(Prototype i, PrototypeSet tData)
i - Prototype whose nearest-neighbors of same and different class will be modified.tData - Data set in which KNN operation will be performed.protected void correct(Prototype i, PrototypeSet tData)
public static void main(java.lang.String[] args)
args - Arguments of the main function.