Skip to ContentSkip to Navigation
Maatschappij/bedrijvenCentrum voor Informatie TechnologieResearch and Innovation SupportVirtual Reality en Visualisatie

FRAME - draws coordinate axes and labels

Example of FRAME output
Example of FRAME output

Introduction

The routine frame draws the horizontal (X) and the vertical (Y) coordinate axis with annotations (labels) of a X-Y graph. Both axes can be linear or logarithmic. A border is drawn around the frame. Moreover, frame defines a mapping between the (X,Y)-coordinates of the points of the data and function drawing routines and the physical axes.

Specification

FRAME( XSIZE, XLEFT, XRIGHT, YSIZE, YLOW , YHIGH, XLAB , YLAB , GLAB)
XLEFT, XRIGHT (real)
coordinates of left and right end of X-axis
XSIZE (real)
The absolute value is the length of X-axis in centimeters. If XSIZE>0.0 then you get a linear X-axis with ticks at every 2 cm (default). The axis numbers of the ticks from left to right are: XLEFT, XLEFT+XSF, XLEFT + 2*XSF, ... where XSF=(XRIGHT - XLEFT)*2/XSIZE. Be careful in the choice of XLEFT and XRIGHT to get 'nice' axis numbers that are easy to interpolate! If XSIZE<0.0 you get a logarithmic X-axis. Be sure that the data, XLEFT and XRIGHT are >0.0!
XLEFT, XRIGHT (real)
Start and end value of the axis. When XLEFT equals XRIGHT the scaling is calculated automatically and axis numbers are computed from the coordinates of the datapoints and function drawing routines in such a way that:
- all points lie within the range of the X-axis;
- for both linear and logarithmic axis;
- 'nice' scaling numbers for linear axis.
XLAB (string)
string with annotation label of X-axis (Unix workstations: <=48 characters, Cray <=64 characters).
YSIZE, YLOW, YHIGH, YLAB
similar parameters for Y-axis.
GLAB (string)
string with graph title plotted near the upper border of the graph.

Example (fortran)

Draw linear X-axis and logarithmic Y-axis:

     call FRAME(10.0, 0.0, 100.0, -8.0, 1.0, 100.0, 'X-axis', 'Y-axis', 'Title')

Remarks

  • A new call to frame starts a new graph.
  • Parts of the graph outside the border are clipped.
  • A lot of attributes of the frame lay-out can be changed. One can for example suppress the border, change the distance of ticks, choose graph style 'scientific', scale annotations.
  • The margins between the ends of the X-axis and the border are default 2 cm. The margins between the ends of the Y-axis and the border are default 1 cm.
  • The labels can have different fonts.
  • Laser printer output (e.g. PostScript) should fit within 19.3*27.9 cm or 27.9*19.3 cm.
  • Some PostScript frame attributes can be modified.
Last modified:15 June 2016 11.46 a.m.