de.aitools.iv.mds.util
Class StressCalulator

java.lang.Object
  extended by de.aitools.iv.mds.util.StressCalulator

public class StressCalulator
extends java.lang.Object

Author:
Anita

Constructor Summary
StressCalulator(java.lang.String v, java.lang.String p, Measure hdm)
          Creates a new instance of StressCalulator.
 
Method Summary
 double calculateStress()
          Calculates stress-1 value.
 void plot(java.lang.String where, java.lang.String name)
          Writes stress value and names of files which have been used for this calculation to .gp file.
 void readPositions()
          Reads file with point coordinates.
 void readVectors()
          Reads file with vectors.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StressCalulator

public StressCalulator(java.lang.String v,
                       java.lang.String p,
                       Measure hdm)
Creates a new instance of StressCalulator.

Parameters:
v - file with vectors (.ntf, .tfidf, .vector generated by Preprocessor)
p - path to .plot file with point coordinates
hdm - high-dimensional measure between objects
Method Detail

readVectors

public void readVectors()
Reads file with vectors.


readPositions

public void readPositions()
Reads file with point coordinates.


calculateStress

public double calculateStress()
Calculates stress-1 value.

Returns:
stress value

plot

public void plot(java.lang.String where,
                 java.lang.String name)
Writes stress value and names of files which have been used for this calculation to .gp file.

Parameters:
where - path to write out file
name - name for output file