uchicago.src.sim.analysis
Class NetSequenceGraph

java.lang.Object
  extended by uchicago.src.sim.analysis.plot.OpenGraph
      extended by uchicago.src.sim.analysis.OpenSequenceGraph
          extended by uchicago.src.sim.analysis.NetSequenceGraph
All Implemented Interfaces:
ZoomListener, MediaProducer

public class NetSequenceGraph
extends OpenSequenceGraph

A graph that captures a series of points (sequences) specialized for network statistics. This is specialized for network stats in that it allows you to add the plotting of such stats on the fly. It also contains methods to easily add such sequences, density, component count, etc. via code. Note that we are currently working on the robustness of these statistics. They should be used only as guides. The actual statistical analysis of your network should be done using established tools.

Version:
$Revision: 1.7 $ $Date: 2004/11/03 19:51:00 $

Field Summary
 
Fields inherited from class uchicago.src.sim.analysis.OpenSequenceGraph
SHOW_ALL, SHOW_FIRST, SHOW_LAST
 
Fields inherited from class uchicago.src.sim.analysis.plot.OpenGraph
CIRCLE, CROSS, DIAMOND, fileName, FILLED_CIRCLE, FILLED_DIAMOND, FILLED_SQUARE, FILLED_TRIANGLE, frame, HISTOGRAM, inNormalState, location, model, movieMaker, plot, PLUS_SIGN, SEQUENCE, SQUARE, title, TRIANGLE, xIncr, xMax, xMin, yIncr, yMax, yMin
 
Fields inherited from interface uchicago.src.sim.gui.MediaProducer
MPEG, QUICK_TIME
 
Constructor Summary
NetSequenceGraph(java.lang.String title, SimModel model, java.util.List nodeList)
          Creates a NetSequencePlot with the specified title for the specified model.
NetSequenceGraph(java.lang.String title, SimModel model, java.lang.String fileName, int fileFormat, java.util.List nodeList)
          Creates a NetSequencePlot with the specified title, model, file name and file format.
 
Method Summary
 void display()
          Displays this graph.
 void plotAvgPathLength(java.lang.String legend)
          Plots the average path length of the network.
 void plotAvgPathLength(java.lang.String legend, java.awt.Color color)
          Plots the average path length of the network.
 void plotAvgPathLength(java.lang.String legend, java.awt.Color color, int markStyle)
          Plots the average path length of the network using the specified parameters.
 void plotAvgPathLength(java.lang.String legend, int markStyle)
          Plots the average path length of the network.
 void plotClusterCoefficient(java.lang.String legend)
          Plots the cluster coefficient of the network.
 void plotClusterCoefficient(java.lang.String legend, java.awt.Color color)
          Plots the cluster coefficient of the network.
 void plotClusterCoefficient(java.lang.String legend, java.awt.Color color, int markStyle)
          Plots the cluster coefficient of the network using the specified parameters.
 void plotClusterCoefficient(java.lang.String legend, int markStyle)
          Plots the cluster coefficient of the network.
 void plotComponentCount(java.lang.String legend)
          Plots the component size of the network.
 void plotComponentCount(java.lang.String legend, java.awt.Color color)
          Plots the component size of the network.
 void plotComponentCount(java.lang.String legend, java.awt.Color color, int markStyle)
          Plots the component size of the network using the specified parameters.
 void plotComponentCount(java.lang.String legend, int markStyle)
          Plots the component size of the network.
 void plotDensity(java.lang.String legend)
          Plots the density of the network.
 void plotDensity(java.lang.String legend, java.awt.Color color)
          Plots the density of the network.
 void plotDensity(java.lang.String legend, java.awt.Color color, int markStyle)
          Plots the density of the network using the specified parameters.
 void plotDensity(java.lang.String legend, int markStyle)
          Plots the density of the network.
 void plotDiameter(java.lang.String legend)
          Plots the diameter of the network.
 void plotDiameter(java.lang.String legend, java.awt.Color color)
          Plots the diameter of the network.
 void plotDiameter(java.lang.String legend, java.awt.Color color, int markStyle)
          Plots the diameter of the network using the specified parameters.
 void plotDiameter(java.lang.String legend, int markStyle)
          Plots the diameter of the network.
 void plotSymmetry(java.lang.String legend)
          Plots the symmetry of the network.
 void plotSymmetry(java.lang.String legend, java.awt.Color color)
          Plots the symmetry of the network.
 void plotSymmetry(java.lang.String legend, java.awt.Color color, int markStyle)
          Plots the symmetry of the network using the specified parameters.
 void plotSymmetry(java.lang.String legend, int markStyle)
          Plots the symmetry of the network.
 
Methods inherited from class uchicago.src.sim.analysis.OpenSequenceGraph
addSequence, addSequence, addSequence, addSequence, createSequence, createSequence, createSequence, createSequence, getXAutoExpand, getXViewPolicy, getYAutoExpand, getYViewPolicy, record, setXAutoExpand, setXRange, setXViewPolicy, setYAutoExpand, setYRange, setYViewPolicy, updateGraph, writeToFile
 
Methods inherited from class uchicago.src.sim.analysis.plot.OpenGraph
addMovieFrame, closeMovie, createBinDataSource, createListBinDataSource, createSequence, dispose, getAxisTitles, getSize, getTitle, getXIncrement, getXRange, getYIncrement, getYRange, setAxisTitles, setBars, setLocation, setMovieName, setSize, setSnapshotFileName, setXIncrement, setXTick, setYIncrement, step, takeSnapshot, updateXTick, zoom
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NetSequenceGraph

public NetSequenceGraph(java.lang.String title,
                        SimModel model,
                        java.util.List nodeList)
Creates a NetSequencePlot with the specified title for the specified model.

Parameters:
title - the title for this graph.
model - the model associated with this graph

NetSequenceGraph

public NetSequenceGraph(java.lang.String title,
                        SimModel model,
                        java.lang.String fileName,
                        int fileFormat,
                        java.util.List nodeList)
Creates a NetSequencePlot with the specified title, model, file name and file format. File name and file format provide are necessary if the data displayed by this graph is to be outputed to a file.

Parameters:
title - the title of the graph.
model - the model associated with this graph
fileName - the file name to be used when this graph is dumped to a file
fileFormat - the format to be used for dumping data to the file. At the moment only PlotModel.CSV (comma delimited) is supported.
Method Detail

display

public void display()
Displays this graph.

Overrides:
display in class OpenGraph

plotDensity

public void plotDensity(java.lang.String legend)
Plots the density of the network. The default color and mark style will be used.

Parameters:
legend - the legend to display for the density sequence

plotDensity

public void plotDensity(java.lang.String legend,
                        java.awt.Color color)
Plots the density of the network. The default mark style will be used.

Parameters:
legend - the legend to display for the density sequence
color - the color of the density sequence plot

plotDensity

public void plotDensity(java.lang.String legend,
                        int markStyle)
Plots the density of the network. The default color will be used.

Parameters:
legend - the legend to display for the density sequence
markStyle - the style (shape etc.) of the point mark to use. The markStyle is one of the following constants: FILLED_CIRCLE, CROSS, SQUARE, FILLED_TRIANGLE, DIAMOND, CIRCLE, PLUS_SIGN, FILLED_SQUARE, TRIANGLE, FILLED_DIAMOND.

plotDensity

public void plotDensity(java.lang.String legend,
                        java.awt.Color color,
                        int markStyle)
Plots the density of the network using the specified parameters.

Parameters:
legend - the legend to display for the density sequence
color - the color of the sequence plot
markStyle - the style (shape etc.) of the point mark to use. The markStyle is one of the following constants: FILLED_CIRCLE, CROSS, SQUARE, FILLED_TRIANGLE, DIAMOND, CIRCLE, PLUS_SIGN, FILLED_SQUARE, TRIANGLE, FILLED_DIAMOND.

plotComponentCount

public void plotComponentCount(java.lang.String legend)
Plots the component size of the network. The default color and mark style will be used.

Parameters:
legend - the legend to display for the component sequence

plotComponentCount

public void plotComponentCount(java.lang.String legend,
                               java.awt.Color color)
Plots the component size of the network. The default mark style will be used.

Parameters:
legend - the legend to display for the component sequence
color - the color of the component sequence plot

plotComponentCount

public void plotComponentCount(java.lang.String legend,
                               int markStyle)
Plots the component size of the network. The default color will be used.

Parameters:
legend - the legend to display for the component sequence
markStyle - the style (shape etc.) of the point mark to use. The markStyle is one of the following constants: FILLED_CIRCLE, CROSS, SQUARE, FILLED_TRIANGLE, DIAMOND, CIRCLE, PLUS_SIGN, FILLED_SQUARE, TRIANGLE, FILLED_DIAMOND.

plotComponentCount

public void plotComponentCount(java.lang.String legend,
                               java.awt.Color color,
                               int markStyle)
Plots the component size of the network using the specified parameters.

Parameters:
legend - the legend to display for the component sequence
color - the color of the sequence plot
markStyle - the style (shape etc.) of the point mark to use. The markStyle is one of the following constants: FILLED_CIRCLE, CROSS, SQUARE, FILLED_TRIANGLE, DIAMOND, CIRCLE, PLUS_SIGN, FILLED_SQUARE, TRIANGLE, FILLED_DIAMOND.

plotClusterCoefficient

public void plotClusterCoefficient(java.lang.String legend)
Plots the cluster coefficient of the network. The default color and mark style will be used.

Parameters:
legend - the legend to display for the cluster coefficient sequence

plotClusterCoefficient

public void plotClusterCoefficient(java.lang.String legend,
                                   java.awt.Color color)
Plots the cluster coefficient of the network. The default mark style will be used.

Parameters:
legend - the legend to display for the cluster coefficient sequence
color - the color of the cluster coefficient sequence plot

plotClusterCoefficient

public void plotClusterCoefficient(java.lang.String legend,
                                   int markStyle)
Plots the cluster coefficient of the network. The default color will be used.

Parameters:
legend - the legend to display for the cluster coefficient sequence
markStyle - the style (shape etc.) of the point mark to use. The markStyle is one of the following constants: FILLED_CIRCLE, CROSS, SQUARE, FILLED_TRIANGLE, DIAMOND, CIRCLE, PLUS_SIGN, FILLED_SQUARE, TRIANGLE, FILLED_DIAMOND.

plotClusterCoefficient

public void plotClusterCoefficient(java.lang.String legend,
                                   java.awt.Color color,
                                   int markStyle)
Plots the cluster coefficient of the network using the specified parameters.

Parameters:
legend - the legend to display for the cluster coefficient sequence
color - the color of the sequence plot
markStyle - the style (shape etc.) of the point mark to use. The markStyle is one of the following constants: FILLED_CIRCLE, CROSS, SQUARE, FILLED_TRIANGLE, DIAMOND, CIRCLE, PLUS_SIGN, FILLED_SQUARE, TRIANGLE, FILLED_DIAMOND.

plotDiameter

public void plotDiameter(java.lang.String legend)
Plots the diameter of the network. The default color and mark style will be used.

Parameters:
legend - the legend to display for the diameter sequence

plotDiameter

public void plotDiameter(java.lang.String legend,
                         java.awt.Color color)
Plots the diameter of the network. The default mark style will be used.

Parameters:
legend - the legend to display for the diameter sequence
color - the color of the diameter sequence plot

plotDiameter

public void plotDiameter(java.lang.String legend,
                         int markStyle)
Plots the diameter of the network. The default color will be used.

Parameters:
legend - the legend to display for the diameter sequence
markStyle - the style (shape etc.) of the point mark to use. The markStyle is one of the following constants: FILLED_CIRCLE, CROSS, SQUARE, FILLED_TRIANGLE, DIAMOND, CIRCLE, PLUS_SIGN, FILLED_SQUARE, TRIANGLE, FILLED_DIAMOND.

plotDiameter

public void plotDiameter(java.lang.String legend,
                         java.awt.Color color,
                         int markStyle)
Plots the diameter of the network using the specified parameters.

Parameters:
legend - the legend to display for the diameter sequence
color - the color of the sequence plot
markStyle - the style (shape etc.) of the point mark to use. The markStyle is one of the following constants: FILLED_CIRCLE, CROSS, SQUARE, FILLED_TRIANGLE, DIAMOND, CIRCLE, PLUS_SIGN, FILLED_SQUARE, TRIANGLE, FILLED_DIAMOND.

plotAvgPathLength

public void plotAvgPathLength(java.lang.String legend)
Plots the average path length of the network. The default color and mark style will be used.

Parameters:
legend - the legend to display for the average path length sequence

plotAvgPathLength

public void plotAvgPathLength(java.lang.String legend,
                              java.awt.Color color)
Plots the average path length of the network. The default mark style will be used.

Parameters:
legend - the legend to display for the average path length sequence
color - the color of the average path length sequence plot

plotAvgPathLength

public void plotAvgPathLength(java.lang.String legend,
                              int markStyle)
Plots the average path length of the network. The default color will be used.

Parameters:
legend - the legend to display for the average path length sequence
markStyle - the style (shape etc.) of the point mark to use. The markStyle is one of the following constants: FILLED_CIRCLE, CROSS, SQUARE, FILLED_TRIANGLE, DIAMOND, CIRCLE, PLUS_SIGN, FILLED_SQUARE, TRIANGLE, FILLED_DIAMOND.

plotAvgPathLength

public void plotAvgPathLength(java.lang.String legend,
                              java.awt.Color color,
                              int markStyle)
Plots the average path length of the network using the specified parameters.

Parameters:
legend - the legend to display for the average path length sequence
color - the color of the sequence plot
markStyle - the style (shape etc.) of the point mark to use. The markStyle is one of the following constants: FILLED_CIRCLE, CROSS, SQUARE, FILLED_TRIANGLE, DIAMOND, CIRCLE, PLUS_SIGN, FILLED_SQUARE, TRIANGLE, FILLED_DIAMOND.

plotSymmetry

public void plotSymmetry(java.lang.String legend)
Plots the symmetry of the network. The default color and mark style will be used.

Parameters:
legend - the legend to display for the symmetry sequence

plotSymmetry

public void plotSymmetry(java.lang.String legend,
                         java.awt.Color color)
Plots the symmetry of the network. The default mark style will be used.

Parameters:
legend - the legend to display for the symmetry sequence
color - the color of the symmetry sequence plot

plotSymmetry

public void plotSymmetry(java.lang.String legend,
                         int markStyle)
Plots the symmetry of the network. The default color will be used.

Parameters:
legend - the legend to display for the symmetry sequence
markStyle - the style (shape etc.) of the point mark to use. The markStyle is one of the following constants: FILLED_CIRCLE, CROSS, SQUARE, FILLED_TRIANGLE, DIAMOND, CIRCLE, PLUS_SIGN, FILLED_SQUARE, TRIANGLE, FILLED_DIAMOND.

plotSymmetry

public void plotSymmetry(java.lang.String legend,
                         java.awt.Color color,
                         int markStyle)
Plots the symmetry of the network using the specified parameters.

Parameters:
legend - the legend to display for the symmetry sequence
color - the color of the sequence plot
markStyle - the style (shape etc.) of the point mark to use. The markStyle is one of the following constants: FILLED_CIRCLE, CROSS, SQUARE, FILLED_TRIANGLE, DIAMOND, CIRCLE, PLUS_SIGN, FILLED_SQUARE, TRIANGLE, FILLED_DIAMOND.