At present, graph plotting in SPROGS entails using SCALA, GRATA, etc. The proposed system tries to take the graft out of graphing and simplify the user's task.
The package may be thought to be at 3 1evels of user control. Level 1 draws the graph, etc, with no options for the user. Level 2 draws the graph, with options, but the user has no control over the scales of the axes, and level 3 draws the graph, with options, and the user must specify the axes scales.
A basic graph plotting routines with no options for the user. It draws the axes, ticking, scales, title and co-ordinates. The co-ordinates are plotted as a continuous graph. Output is to SD4020 hardcopy only (?).
The arguments are:
XAR array of X co-ordinates YAR array of Y co-ordinates CORDNO Number of co-ordinates (must be positive) COUNT Number of characters in TITLE TITLE Hollerith argument of COUNT characters.
In more detail this means:
(a) Call SDHARD to fix the region.
(b) Draws X and Y axes with VEC (100,100,980,100) and VEC (100,100,100,980).
(c) MAX and MINX and Y ordinates found and axes scaled accordingly. The scaling is done to the following format:
F mode in the range ±0.0001 to ±100000. E mode if outside this range
(d) Ten major divisions and minor divisions (ticking) per axis, drawn inside the graph area. Major divisions are 16 rasters long and minor divisions 8 rasters.
(e) Title drawn at the top of the graph, but outside the area of the graph, ie SETXY (400,990).
(f) Co-ordinates plotted (RGLIM forced to give co-ordinate conversion) and continuous graph drawn. Frame advance issued.
GRAPH2 differs from GRAPH1 in using the current region selected by the user and, consequently, the user also selects the output medium. The axes are drawn on the boundary of the region and the exterior visibility is forced to allow the printing of the scales on the outside of the region. Again, XMAX/MIN, IMAX/MIN are found and RGLIM forced to allow conversion and plotting. Three further arguments are added to those already mentioned in GRAPH1. These are:
GRATIC = 0.0 - No graticules or ticking GRATIC = 1.0 - Ticking with major and minor divisions GRATIC = 2.0 - Ticking with major divisions only GRATIC = 3.0 - Major graticule markings only GRATIC = 4.0 - Major and minor graticule markings. FORM = 0.0 - Scales printed as in 1(c) FORM = 1.0 - Scales printed in I mode PLOT = 1-64 - The character specified by the SPROGS number is plotted PLOT = 0 - The plotting is a continuous graph PLOT = ANAME(filename) used in conjunction with a negative CORDNO argument. Allows the transfer of basic filename (GRAPH 4 & 5)
As GRAPH2, but the axes are fixed by the user. RGLIM is unchanged and no co-ordinate conversion takes place.
As GRAPH2. However, argument CORDNO is negative and no co-ordinate plotting takes place. The resulting 'background' graph is saved in a basic file named in the PLOT argument. f XMAX=XMIN=0 or YMAX=YMIN=0, then the relevant axis is not drawn.
As GRAPH4, but the axes are fixed by the user (as in GRAPH3).
GRAPH6 draws the Y axis only. MAX and MIN Y are found and the axis is scaled accordingly. All normal options apply.
As GRAPH6, but draws the X axis only.
In terms of viability, GRAPH2 to GRAPH5 would seem to be the routines to concentrate on at present, with GRAPH1, GRAPH6 and GRAPH7, and possibly log scales, a smoothing routine and multiple graphs as further extensions.