Process Help

PLOTFT - plot linear log and probability axes and a frame

 

Process Name

Menu Path

Link to Command Table

PLOTFT

Command line only

Click here

Introduction

Generates a frame plot, with linear, log and probability options for each axis. The plot consists of a choice of frames, grid or tick marks, with annotation and user-defined titles on each axis.

How to use

This is a general process, which may be used to add a frame and axes to any plot. The usual method of operation is to generate a frame plot when the user is satisfied with the plot of the data to which the frame is to be added. The components are:-

Frame

  1. An inner box around the data area (the X and Y axes).

  2. An optional outer box around the data area at a spacing from the inner box of half the @CHARSIZE parameter (values of the @IGRIDX parameter from 0 to 4 inclusive).

  3. An optional box around the full plot area (negative values of the @IGRIDX parameter).

The data and plot area sizes are taken from the prototype, or defined to be the screen size if the null plot prototype plotprot is used.

Numbering

Annotation at each tick mark or each grid mark.

Tick Marks

Out: Tickmarks outwards from the inner box around the data area.

In: Tickmarks inwards from the inner box around the data area.

Grid

A full grid of intersecting lines in place of the tick marks. In addition, up to 80 characters of label are permitted on each axis. These are prompted for. The labels start from the origin (bottom left-hand corner of the data area), so that spaces should be inserted at the start of the label to space the text along the axes. Tickmarks and grids start from the XMIN, YMIN values. If a number of plots are to be generated with the same scales and axes, then it is only necessary to generate a single frame using PLOTFT. This can then be joined to any data plot file required by using the APPEND process.


Files, Fields and Parameters

Input Files

Name

Description

I/O Status

Required

Type

PROTO

Plot prototype file. Must contain the fields X, Y, S1, S2 and CODE (numeric, explicit) and XMIN, XMAX, YMIN, YMAX, XSCALE, YSCALE (numeric, implicit). If these last 6 values set in PROTO , then corresponding parameters need not be set.

Input

Yes

Plot Prototype

Output Files

Name

I/O Status

Required

Type

Description

PLOT

Output

Yes

Plot

Output plot file.

Parameters

Name

Description

Required

Default

Range

Values

XTYPE

 

Option

Description

1

linear

2

log base 10

3

log base e

4

probability x scale Min/max limits must be defined in the appropriate transformed units (e.g. logs, or for probability, phi unit values in the range of say -4 to +4)

Yes

1

1,4

1,2,3,4

YTYPE

 

Option

Description

1

linear

2

log base 10

3

log base e

4

probability y scale. Min/max limits must be defined in the appropriate transformed units (e.g. logs, or for probability, phi unit values in the range of say -4 to +4)

Yes

1

1,4

1,2,3,4

NDX

Annotation decimal places on X axis.

Yes

Undefined

Undefined

Undefined

NDY

Annotation decimal places on Y axis.

Yes

Undefined

Undefined

Undefined

IGRIDX

 

Option

Description

0

frame only

1

frame + outwards ticks

2

frame + inwards and outwards tick

3

frame + inwards tick

4

grid

5-9

as 0-4 minus frame. Negative value will cause outer frame around full plot area.

Yes

0

0,10

Undefined

IGRIDY

 

Option

Description

0

no numbering

1

outwards ticks

2

inwards and outwards ticks

3

inwards ticks

4

grid;

Yes

Undefined

0,4

0,1,2,3,4

NOXAXIS

>0 suppresses plotting of X-axis (0).

No

0

Undefined

Undefined

NOYAXIS

>0 suppresses plotting of Y-axis (0).

No

0

Undefined

Undefined

CHARSIZE

Character size in millimetres (3).

No

3

Undefined

Undefined

ASPRATIO

Aspect ratio, width / ht. for chars (0.9).

No

0.9

Undefined

Undefined

 

Colour [as 'pen' number] for plot (1).

No

1

Undefined

Undefined

APPEND

Plot append flag. If set to 1 then the new plot will be appended to the PLOT file, if it exists and is a valid plot file (0).

No

0

0,1

0,1

XMIN

Minimum value of X for plot. None of XMIN, XMAX, YMIN, YMAX, XSCALE, YSCALE need be set if this information is already in the prototype.

No

Undefined

Undefined

Undefined

XMAX

Maximum value of X for plot.

No

Undefined

Undefined

Undefined

YMIN

Minimum value of Y for plot.

No

Undefined

Undefined

Undefined

YMAX

Maximum value of Y for plot.

No

Undefined

Undefined

Undefined

XSCALE

X scale in user data units per millimetre.

No

Undefined

Undefined

Undefined

YSCALE

Y scale in user data units per millimetre.

No

Undefined

Undefined

Undefined


Notes

  1. Probability data to be plotted with the PLOTFT output plot file as plot prototype is generated by process RANK. The PHI field, generated by the RANK, process contains the standard normal deviate values (alternatively identified as Z in many statistical texts) normally in the range -4.0 to +4.0. Hence appropriate minimum and maximum values for the probability scale axis should be supplied to PLOTFT, based on the range of the PHI field data.

  2. For log scale plotting, a logarithmic transformation of data values can be performed using process EXTRA. The actual minimum and maximum of the log values will be required for defining the axis limits in process PLOTFT. A four cycle plot will be produced from a minimum of -1 and a maximum of 3.0. All logarithms are assumed to be computed for base 10.


Example

Example 1

The following will produce a frame plot with a log base 10 X axis from 0.1 to 1000.0 (4 cycles) and a probability Y axis from .001 to .999.  

!PLOTFT  

 

 &PROTO(PLOTPROT), &PLOT(FFRAME),@XTYPE=2,@YTYPE=4, @NDX=1,@NDY=0,@IGRIDX=4,@IGRIDY=4,@XMIN=-1,@XMAX=3, @YMIN=-3.5,@YMAX=3.5

 

XLABEL> LOG concentration - ppm

 

YLABEL> Cumulative frequency

Example 2

!PROTOP  

 &OUT(PROTOFT)

 

OPT>10

 

DATA AREA X ORIGIN>50

 

DATA AREA Y ORIGIN>50

 

DATA AREA X SIZE>200

 

DATA AREA Y SIZE>100

 

DO YOU WISH TO DEFINE SCALING IN THIS PROTOTYPE Y/(N) ?>N

 

CONFIRM ?>Y

!PLOTFT  

 &PROTO(PROTOFT),&PLOT(PLOTFT),@XTYPE=2.0,@YTYPE=1.0,@NDX=1.0, @NDY=0.0,@IGRIDX=4.0,@IGRIDY=4.0,@NOXAXIS=0.0,@NOYAXIS=0.0, @CHARSIZE=1.5,@ASPRATIO=0.9,@=1.0,@APPEND=0.0, @XMIN=-4.0,@XMAX=4.0,@YMIN=0.0,@YMAX=100.0

 

XLABEL > Particle size (mm)

 

YLABEL > Percentage passing (%)

!GENTRA  

 &IN(INDATA),&OUT(LOGDATA)

 

TRAN>LOG LOGPAR PARSIZE

 

TRAN>END

 

CONFIRM ?>Y

!PLOTLI  

 &IN(LOGDATA),&PROTO(PLOTFT),&PLOT(PLOTDATA),*X(LOGPAR), *Y(PERPASS),@LINECODE=2.0,@SYMBOL=93.0,@SYMSIZE=1.5, @=2.0,@APPEND=0.0,@XMIN=-4.0,@XMAX=4.0,@YMIN=0.0, @YMAX=100.0

!APPEND  

 &IN1(PLOTFT),&IN2(PLOTDATA),&OUT(PLOTFT1),@PRINT=0.0


Error and Warning Messages

Message

Description

Solution

>>> CANNOT APPEND TO NON-EXISTENT OUTPUT FILE.

>>> A NEW OUTPUT FILE WILL BE CREATED

The @APPEND parameter has been set to 1, but the specified plot file does not exist. A new file will be created to contain the new plot being produced.

 

 

 

 

 

>>> ERROR - CANNOT APPEND TO PLOT FILE AS IT DOES

>>> NOT CONTAIN ALL THE REQUIRED FIELDS.

>>> THE PLOT FILE WILL BE OVERWRITTEN.

The @APPEND parameter has been set to 1, the specified plot file exists but is invalid. The existing plot file will be overwritten by the new plot being produced.

 

 

 

 

 

>>> FATAL ERROR, BAD SCALE/RANGE COMBINATION(S) <<<

>>> XMIN, XMAX = nnnnnnnnnn.nn nnnnnnnnn.nn

>>> YMIN, YMAX = nnnnnnnnnn.nn nnnnnnnnn.nn

>>> XSCALE, YSCALE = nnnnnnnnnn.nn nnnnnnnnn.nn

Either insufficient scale information had been entered (at least two of XMIN, XMAX, XSCALE or Y equivalents must be entered either from the prototype of from parameters) or the combination given of XMIN, XMAX, and XSCALE (or their Y equivalents) was impossible. Often caused by entering a null plot prototype and no parameters. Fatal; the process is exited.