plots x- and/or y-axes and scales the user units

xleft,ybotfloatuuvalue at the left/low end of the axes
xright,ytopfloatuuvalue at the right/high end of the axes
xlen,ylenfloatmmlengths of the axes
xtext,ytextchar*--strings plotted at the right/upper end of the axes
textchar*--string plotted at the left end of the x-axis


plaxes plots x- and y-axes and sets scale factors and user origin The placement of axes and numbers along the axes is governed by global variables set by plset (T=TRUE, F=FALSE):
globaldefaultvaluedescription \b
X/YINF/FTnumber at the right/above of the x/y axis
Fat the left/under
X/YSQUART/FTnumber square to the x/y-axis
Fnumber in the direction of the x/y-axis
X/YANGLE0/90valdirections of the axes relative to the initial x-axis; any angle is permitted
CROSSFTaxes cross at user unit set by X/YCROSS
Faxes cross at xleft,ybot
X/YCROSSxleft/ybotvaly/x axis crosses the x/y axis at val user units if CROSS has been set to a non-zero value
X/YMARK0/0valx/y axis scale marks are placed every val user units
0x/y axis scale marks are placed automatically
X/YSKIP0valx/y axis numbers are placed at every val scale mark
0x/y axis numbers are placed automatically
X/YGRIDFTgrid lines at plotted through the numbered scale marks of the y/x axis
Fno grid lines are plotted


Plaxes plots in GXcopy mode, even if the user has set another mode.


several features: plotting of a single axis by setting xl=0 or xleft=xright, plotting of scale ticks and number to the left or to the right of the axis, and the usage of YMARK:
#include <simplot.h>
#include <stdio.h>
int main() {
   int i,Fmin=-22,Fmax=158,Cmin=-30,Cmax=70;


   for (i=0;i<=66;i+=66) {
      // note that we need tricks to put the Celsius and the Fahrenheit
      // on the correct side. Celsius is put above the Fahrenheit axis
      // and vice versa, and spaces are used for shifting

      plaxes(0,Fmin,0,Fmax,0,200,"","   #0#Celsius","");
      // plots vertical scale; x-axis not used
      // numbers will be plotted "inside", that is: right of y-axis
      // moves origin 2 mm to the right
      plaxes(0,Cmin,0,Cmax,0,200," ","#0#Fahrenheit   "," ");
      // plots celsius scale 2 mm right of fahrenheit scale
      // resets plotting 'outside' that is: left of y-axis
      // causes plotting of scale marks at each degree
   plformat(0,0,"Temperature scales");


See also

plpoly plarc plfont plpline plhist plarcr plformat plloop plmvorg simplot program plfunc plpolar plrotate pltrace plpolv