org.hisee.core
Class Gauge

java.lang.Object
  |
  +--org.hisee.core.Gauge

public class Gauge
extends java.lang.Object

Gauge is the main class of the high dimensional visualizer, which manages both command -line and GUI interfaces, and provides methods for changing and initializing various projection algorithms.


Field Summary
protected  GaugePanel gp
           
static java.lang.String[] PROJECTOR_LIST
           
 
Constructor Summary
Gauge(boolean useGraphics)
          Constructor
Gauge(int x, int y, int w, int h)
          Construct a GUI Gauge with specified frame parameters.
 
Method Summary
 void addDatapoint(double[] point)
          Add a new point to the dataset, using the currently selected add method.
 java.lang.String getDefaultDir()
           
 Dataset getDownstairs()
          Convenience method to get downstairs dataset
 double getError()
          Returns error, which is only set by some projection functions
 GaugePanel getGp()
           
 java.lang.String getName()
           
 Projector getProjector()
           
static java.lang.String[] getProjectorList()
           
 Dataset getUpstairs()
          Convenience method to get upstairs dataset
 void init(int dims)
          Initialize gauge to accept data of a specified dimension.
 boolean isOn()
          If the gauge is on it should actively represent changing states of the network
 boolean isUsingGraphics()
           
 boolean isUsingHotPoint()
           
 boolean isUsingOnOff()
          The onOff button is only used with certain components, where the ability to add new data is important.
 void iterate(int num_times)
          Iterate the dataset some fixed number of times
static void main(java.lang.String[] args)
          Main method
 void openHighDDataset(java.io.File file)
           
 void setBounds(int x, int y, int width, int height)
          Forwards parameters to Frame object, to set location of gauge panel
 void setCurrentProjector(Projector proj)
           
 void setCurrentProjector(java.lang.String proj)
           
 void setDefaultDir(java.lang.String string)
           
 void setName(java.lang.String string)
           
 void setOn(boolean b)
          Turn the gauge on and off; i.e., allow new data or not.
 void setUsingGraphics(boolean b)
           
 void setUsingHotPoint(boolean b)
          Turn off "hot point" capability on or off, which sets the "current" state of some dataset to a specified color, e.g red
 void setUsingOnOff(boolean b)
          The onOff button is only used with certain components, where the ability to add new data is important.
 void updateProjector()
          Update the projector; used when loading a dataset or changing projection methods
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

gp

protected GaugePanel gp

PROJECTOR_LIST

public static final java.lang.String[] PROJECTOR_LIST
Constructor Detail

Gauge

public Gauge(boolean useGraphics)
Constructor

Parameters:
useGraphics - true if graphics should be used, false otherwise

Gauge

public Gauge(int x,
             int y,
             int w,
             int h)
Construct a GUI Gauge with specified frame parameters. Currently used when creating a gauge within another application

Parameters:
x - x location
y - y location
w - width
h - height
Method Detail

main

public static void main(java.lang.String[] args)
Main method


updateProjector

public void updateProjector()
Update the projector; used when loading a dataset or changing projection methods


init

public void init(int dims)
Initialize gauge to accept data of a specified dimension.

Parameters:
dims - dimensionality of the high dimensional dataset

openHighDDataset

public void openHighDDataset(java.io.File file)

addDatapoint

public void addDatapoint(double[] point)
Add a new point to the dataset, using the currently selected add method.

Parameters:
point - the point to add

setBounds

public void setBounds(int x,
                      int y,
                      int width,
                      int height)
Forwards parameters to Frame object, to set location of gauge panel


iterate

public void iterate(int num_times)
Iterate the dataset some fixed number of times

Parameters:
num_times - Number of times to iterate the gauge

getProjectorList

public static java.lang.String[] getProjectorList()
Returns:
list of projector types, by name

setCurrentProjector

public void setCurrentProjector(java.lang.String proj)

setCurrentProjector

public void setCurrentProjector(Projector proj)

getProjector

public Projector getProjector()
Returns:
the current projection algorithm

getUpstairs

public Dataset getUpstairs()
Convenience method to get upstairs dataset

Returns:
hi-dimensional dataset associated with current projector

getDownstairs

public Dataset getDownstairs()
Convenience method to get downstairs dataset

Returns:
low-dimensional dataset associated with current projector

getName

public java.lang.String getName()
Returns:
name of gauge

setName

public void setName(java.lang.String string)
Parameters:
string - name of gauge

getError

public double getError()
Returns error, which is only set by some projection functions

Returns:
current error

isOn

public boolean isOn()
If the gauge is on it should actively represent changing states of the network

Returns:
true if the gauge is on

setOn

public void setOn(boolean b)
Turn the gauge on and off; i.e., allow new data or not. Used mainly when the Gauge is a component in another application

Parameters:
b -

isUsingGraphics

public boolean isUsingGraphics()
Returns:
true if the Gauge is in GUI mode, false otherwise

setUsingGraphics

public void setUsingGraphics(boolean b)
Parameters:
b - sets whether the Gauge is using graphics or not

setUsingHotPoint

public void setUsingHotPoint(boolean b)
Turn off "hot point" capability on or off, which sets the "current" state of some dataset to a specified color, e.g red

Parameters:
b - sets whether hot points are being used or not

isUsingHotPoint

public boolean isUsingHotPoint()
Returns:
true if hot points are being used, false otherwise

getDefaultDir

public java.lang.String getDefaultDir()
Returns:
the default directory where datasets are stored

setDefaultDir

public void setDefaultDir(java.lang.String string)
Parameters:
string - the default directory where dataset are stored

getGp

public GaugePanel getGp()
Returns:
reference to gauge panel, the main GUI component

isUsingOnOff

public boolean isUsingOnOff()
The onOff button is only used with certain components, where the ability to add new data is important.

Returns:
whether the onOff button is being being used

setUsingOnOff

public void setUsingOnOff(boolean b)
The onOff button is only used with certain components, where the ability to add new data is important.



for more information see hisee.sourceforge.net