ii_plotting.js

Graph Layout Control Variables

The following variables control the appearance of the graph.

Behaviour Control variables

And these control the internal behaviour and so how it might interact with other things using the applet.

Plotting Functions

Here are the actual plotting functions.

axis = plotting_make_axis(objects, col, type, convert, size)

Calculate the details of an axis. Objects is an array of arrays giving the data which will be plotted. Col is the index into a row at which to find the data for this axis. Type is the type of axis. Convert, if non-null, is a function which will be called on each value to get the actual value to be plotted. For example it might scale numeric data or convert postcodes to all capitals. Size is the size of the area over which the data will be plotted. If size is width:plot size or height:plot size the size will be calculated from the size of the applet and the offsets defined by the layout variables above.

plotting_plot_data(xaxis, yaxis, zaxis)

Plots the data on the applet. Xaxis and yaxis are axes returned from previous calls to plotting_make_axis for the X and Y axes. If given, zaxis is used to select which image to use for each point as if it were an axis.

plotting_plot_xaxis(XName, xaxis, YName, yaxis, ZName, zaxis)

Plot and label the axes. The *Name parameters are the names to be written on the axes. As with plotting_plot_data, the parameters relating to the Z axis can be omitted.

Callbacks

The following callbacks can be defined to tailor the action of the library.

index = plotting_image_selector(values)

If defined, this is called when the library needs to decide which marker image to use to plot a point. Values is the list of values from a row of the data array.