AFLPgui
Class Graph

java.lang.Object
  |
  +--AFLPgui.Graph
Direct Known Subclasses:
BarGraph, ScatterGraph

public abstract class Graph
extends java.lang.Object

This abstract class provides a way for other parts of the program to draw graphs easily. Classes can extend this and actually draw the graph. For example, a graph could be a bar graph showing the different peaks in a lane.


Constructor Summary
Graph()
           
 
Method Summary
abstract  void drawGraph(java.awt.Graphics g, int x, int y, int width, int height, int bottom_border, double scale, double minSize, double maxSize, DataList lanes)
          Draw some sort of graph given the specified parameters.
abstract  int getPreferredWidth()
          Gives the ideal size of the graph.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Graph

public Graph()
Method Detail

drawGraph

public abstract void drawGraph(java.awt.Graphics g,
                               int x,
                               int y,
                               int width,
                               int height,
                               int bottom_border,
                               double scale,
                               double minSize,
                               double maxSize,
                               DataList lanes)
Draw some sort of graph given the specified parameters. The graph should not draw outside of the given region.
Parameters:
g - the graphics to draw on
x - the x coordinate of the upper left corner of the graph area. (The position of the vertical axis)
y - the y coordinate of the upper left corner of the graph
width - the width of the graph area.
height - the height of the graph
scale - the scale of the graph, pixel = intensity*scale
minSize - the minimum size, in bp, that the graph should include
maxSize - the maximum size, in bp, that the graph should include
lanes - the lanes to include in the graph.

getPreferredWidth

public abstract int getPreferredWidth()
Gives the ideal size of the graph. Should return -1 if the graph doesn't care what size it is.