|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.awt.Component | +--java.awt.Canvas | +--GRAph
This class implements a 2D graph capable of graphing several data sets
Inner Class Summary | |
class |
GRAph.monthDay
Inner class providing calendar functions. |
Field Summary | |
java.awt.Color[] |
graph_colors
|
double[][][] |
graph_data
Three dimensional array of data points to be plotted. |
java.lang.String |
graph_title
Graph title |
boolean |
gridOn
Boolean variable setting grid on or off. |
int |
margin_bottom
Pixels between bottom of graph and bottom of window. |
int |
margin_left
Pixels between left side of graph and left side of window. |
int |
margin_right
Pixels between right side of graph and right side of window. |
int |
margin_top
Pixels between top of graph and top of window. |
static int[] |
MONTH_DAYS
Array giving the starting day number in the year for the first day of each of the 12 months. |
static int |
NORMAL
Used to specify X axis mode (alternatively, TIME). |
int |
ticSize
Size of the tic marks on the X and Y axes, in pixels. |
static int |
TIME
Used to specify X axis mode (alternatively, NORMAL). |
int |
xAxisMode
Defines the mode of the X axis display, NORMAL or TIME. |
double |
xGridInterval
Interval between grid lines in X direction. |
double |
xGridOrigin
Position of grid origin. |
double |
xmax
Defines right boundary of the graph. |
double |
xmin
Defines left boundary of the graph. |
double |
yGridInterval
Interval between grid lines in Y direction. |
double |
yGridOrigin
Position of grid origin. |
double |
ymax
Defines top boundary of the graph. |
double |
ymin
Defines bottom boundary of the graph. |
Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT,
CENTER_ALIGNMENT,
LEFT_ALIGNMENT,
RIGHT_ALIGNMENT,
TOP_ALIGNMENT |
Constructor Summary | |
GRAph(java.awt.Color[] graph_colors)
Constructor for GRAph data object. |
Method Summary | |
void |
autoscale(double[][][] graph_data)
|
void |
autoscaleX(double[][][] graph_data)
|
void |
autoscaleY(double[][][] graph_data)
|
void |
drawTimeTics(java.awt.Graphics g)
Draw a set of tics for time-marked axis. |
void |
graphit(double[][][] graph_data)
If invoked without the bounds being specified, autoscale() is first invoked to set plotting bounds. |
void |
graphit(double xmin,
double xmax,
double ymin,
double ymax,
double[][][] graph_data)
Used to draw a graph. |
void |
paint(java.awt.Graphics g)
This routine is called whenever something changes, to render the graph. |
Methods inherited from class java.awt.Canvas |
addNotify |
Methods inherited from class java.awt.Component |
action,
add,
addComponentListener,
addFocusListener,
addInputMethodListener,
addKeyListener,
addMouseListener,
addMouseMotionListener,
addPropertyChangeListener,
addPropertyChangeListener,
bounds,
checkImage,
checkImage,
coalesceEvents,
contains,
contains,
createImage,
createImage,
deliverEvent,
disable,
disableEvents,
dispatchEvent,
doLayout,
enable,
enable,
enableEvents,
enableInputMethods,
firePropertyChange,
getAlignmentX,
getAlignmentY,
getBackground,
getBounds,
getBounds,
getColorModel,
getComponentAt,
getComponentAt,
getComponentOrientation,
getCursor,
getDropTarget,
getFont,
getFontMetrics,
getForeground,
getGraphics,
getHeight,
getInputContext,
getInputMethodRequests,
getLocale,
getLocation,
getLocation,
getLocationOnScreen,
getMaximumSize,
getMinimumSize,
getName,
getParent,
getPeer,
getPreferredSize,
getSize,
getSize,
getToolkit,
getTreeLock,
getWidth,
getX,
getY,
gotFocus,
handleEvent,
hasFocus,
hide,
imageUpdate,
inside,
invalidate,
isDisplayable,
isDoubleBuffered,
isEnabled,
isFocusTraversable,
isLightweight,
isOpaque,
isShowing,
isValid,
isVisible,
keyDown,
keyUp,
layout,
list,
list,
list,
list,
list,
locate,
location,
lostFocus,
minimumSize,
mouseDown,
mouseDrag,
mouseEnter,
mouseExit,
mouseMove,
mouseUp,
move,
nextFocus,
paintAll,
paramString,
postEvent,
preferredSize,
prepareImage,
prepareImage,
print,
printAll,
processComponentEvent,
processEvent,
processFocusEvent,
processInputMethodEvent,
processKeyEvent,
processMouseEvent,
processMouseMotionEvent,
remove,
removeComponentListener,
removeFocusListener,
removeInputMethodListener,
removeKeyListener,
removeMouseListener,
removeMouseMotionListener,
removeNotify,
removePropertyChangeListener,
removePropertyChangeListener,
repaint,
repaint,
repaint,
repaint,
requestFocus,
reshape,
resize,
resize,
setBackground,
setBounds,
setBounds,
setComponentOrientation,
setCursor,
setDropTarget,
setEnabled,
setFont,
setForeground,
setLocale,
setLocation,
setLocation,
setName,
setSize,
setSize,
setVisible,
show,
show,
size,
toString,
transferFocus,
update,
validate |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
wait,
wait,
wait |
Field Detail |
public static final int TIME
public static final int NORMAL
public static final int[] MONTH_DAYS
public int xAxisMode
public double xmin
public double xmax
public double ymin
public double ymax
public int margin_top
public int margin_bottom
public int margin_left
public int margin_right
public java.lang.String graph_title
public double xGridInterval
public double yGridInterval
public double xGridOrigin
public double yGridOrigin
public int ticSize
public boolean gridOn
public double[][][] graph_data
public java.awt.Color[] graph_colors
Constructor Detail |
public GRAph(java.awt.Color[] graph_colors)
Method Detail |
public void graphit(double xmin, double xmax, double ymin, double ymax, double[][][] graph_data)
public void graphit(double[][][] graph_data)
public void paint(java.awt.Graphics g)
public void drawTimeTics(java.awt.Graphics g)
public void autoscaleX(double[][][] graph_data)
public void autoscaleY(double[][][] graph_data)
public void autoscale(double[][][] graph_data)
|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |