Last Updated: 3/4/97
Class NFStripChartApp

Class NFStripChartApp

public class NFStripChartApp extends Applet

This class supports the generation of Strip Charts, which are ideal for displaying time based data that is periodically updated. Some examples are performance meters, currency tracking, stock tracking, seismograph, and so on. The Strip Chart is designed to make implementing this type of chart easy, fast, and Internet accessible.

The Strip Chart is based on a certain number of "slots" in the X axis. The slots are equally divided into the available graphing space and represent a particular point in time. The rightmost slot contains the newest data, and the leftmost slot has the oldest displayed data. Data in multiple data sets is added synchronously, with one point being extracted from each dataset as each new slot is added.

Note that data is only displayed in the graph after the Update parameter (described below) is passed.

The following standard parameters are supported by this chart:

 	Background

 	Header
 	HeaderBox
 	Footer
 	FooterBox
 	LeftTitle
 	LeftTitleBox
 	RightTitle
 	RightTitleBox

 	DwellLabel
 	DwellBox
 	ActiveClicks
 	ActiveLabels[1-50]

 	Legend
 	LegendBox
 	LegendItems

 	LeftAxis
 	RightAxis

 	Grid
 	GridLine
 	GridAxis

 	ColorTable

 	NoteSets
 	NoteSets[1-20]
 	NoteArrow
 	NoteAxis
 	NoteLabel
 	NoteBox

The following parameters are specifically supported by this chart:

DataSets = (dataset1 tuple), (dataset2 tuple),...;

 	Defines a list of dataset tuples with the following attributes
 	in each tuple:

 	"Name"    - Name assigned to this data set
 	SymColor  - Symbol Color
 	SymType   - Symbol Type (CIRCLE, SQUARE, DIAMOND, CROSS,
 				 TRIANGLEDOWN, TRIANGLEUP, VRECTANGLE)
 	SymSize   - Symbol Size (in pixels)
 	SymStyle  - Symbol Style (FILLED, OUTLINED)
 	LineType  - Line Type (SOLID, DOTTED, DASHED, DOTDASH)
 	LineWidth - Line Width (in pixels)
 	LineColor - Line Color

 	By default, the Name and SymColor will be used as items 
 	in the Legend.

 	If any of the symbol attributes are undefined, default 
 	values will be used.

 	If the LineType attribute is defined, the data symbols 
 	in the given data set will be connected by line 
 	segments using the given line attributes.

 	At most 50 datasets may be displayed.

 	If a color is not specified in the vector, then the 
 	previously specified color will be used. If the color is
 	specified as "null", then a default color will be chosen
 	from the color table. (See the ColorTable parameter.)

 	If a line color or fill color is assigned "null", then
 	the line or area fill will not be drawn.

DataAxis = (XAxis1, YAxis1), (XAxis2, YAxis2), ...;

 	The XAxis and YAxis attributes define the specific axis
 	to be used when mapping the X and Y values respectively
 	for each data set defined. The XAxis attribute may be 
 	set to BOTTOM or TOP, while the YAxis may be set to LEFT
 	or RIGHT.

AppendDataSet[1-50] = y1, y2, y3, ...;

 	Defines a list of y values for each dataset defined 
 	by the DataSets parameter.  The data is appended onto
 	the data queue for the specified dataset.  Data is
 	extracted from the queue when an "Update" (described below)
 	statement is passed.  If the value "null" is substituted
 	for a y value, the symbol is not drawn for that slot.

StripLayout = (NumberOfSlots, InitialFill, MaxFill, UndefinedString);

 	Specifies basic strip chart information.  The NumberOfSlots
 	parameters identifies how many "steps" there are in the
 	chart's X axis.  InitialFill is either LEFT or RIGHT and
 	indicates which side of the chart the data should begin
 	fill from.  The MaxFill parameter indicates the maximum
 	number of datapoints that can be simultaneously loaded without
 	loss.  The UndefinedString is the string used when a tic
 	is shown but no data for the tic is available.

TopScale = (SlotsPerTic, TicStart, TicStep, AxisType);

BottomScale = (SlotsPerTic, TicStart, TicStep, AxisType);

 	SlotsPerTic represents the number of slots between tic marks.
 	TicStart and TicStep are only used when automatically
 	generating labels and indicate the first tic value and 
 	the numerical increment.  AxisType, which can be either
 	STATIC or DYNAMIC controls the behavior of the Axis.  With
 	a STATIC axis, the tics never move, and each slot has an
 	associated label.  If more labels are added to the axis, the
 	slots (but not tics) will shift.  When the DYNAMIC axis type
 	is used, both tics and labels will move synchronously as
 	data is added.  STATIC tics are faster than DYNAMIC tics.

TopLabels = "Label1", "Label2", "Label3", ...;

BottomLabels = "Label1", "Label2", "Label3", ...;

 	Defines the specific labels to be used for the tic marks
 	along the axis.  If no labels are defined, they will be
 	automatically generated, based on the TicStart and TicStep
 	values defined in the corresponding axis parameter (i.e.
 	TopAxis or BottomAxis).  Labels can be added at any time, 
 	and are appended to the end of the label queue.  

Update;

 	Causes one "slot" of data to be extracted from the input
 	data queue for each data set and displayed.  Update will
 	also update the axes and configure the dwell labels for
 	the slot (if defined).

Instance Variables

Type Name Description Default
public NFStripChart Underlying strip chart object stripchart