HALFAX(3NCARG)

πŸ“¦ version 6.6.2, in epel 9, fedora 43, fedora 44

✨ HALFAX ✨

okay bestie, gather round, because we're talking about HALFAX from the NCAR Graphics world (that's the 3NCARG manual section, iykyk) πŸ’–

What does it do? It draws orthogonal axes that intersect at a point you specify, and it slaps a set of labels on them that you also specify. That's it. That's the whole vibe. Two axes, one intersection point, labels if you want 'em. πŸŽ€


πŸ“œ SYNOPSIS

CALL HALFAX (MJRX,MNRX,MJRY,MNRY,XINT,YINT,IXLB,IYLB)

🌈 C-BINDING SYNOPSIS

#include <ncarg/ncargC.h>

void c_halfax (int mjrx, int mnrx, int mjry, int mnry,
float xint, float yint, int ixlb, int iylb)

πŸ’… DESCRIPTION

okay so here's the tea on every single argument, no skips, we're doing all of them 🫢

  • MJRX, MNRX, MJRY, MNRY β€” these are input expressions of type INTEGER. They set the major and minor divisions of the horizontal (X) axis and the vertical (Y) axis of the current viewport. But β€” and this is the plot twist β€” what they actually mean depends on whatever the internal parameter Β΄LSΒ΄ of SPPS is currently set to. So let's break it down, because it's giving "two completely different moods" 😭
    • 🌸 If the value of Β΄LSΒ΄ implies that the axis is linear: MJRX(Y) specifies the number of major divisions of the X(Y) axis, and MNRX(Y) specifies the number of minor divisions within each major division. And here's the sneaky part, bestie: in each case the value is the number of spaces between grid lines or ticks β€” NOT the number of lines or ticks themselves. So, including the ones sitting at the ends of the axes, there is always one more major division line or mark than the number of major divisions you gave in MJRX(Y). Similarly, there is always one less minor division line or tick per major division than the number of minor divisions per major division you gave in MNRX(Y). math is mathing, just backwards, we love that for us πŸ’€
    • πŸ¦‹ If the value of Β΄LSΒ΄ implies that the axis is logarithmic: every major division point lands at a value of 10**MJRX(Y) times the previous point. example time: if the minimum X-axis value were 3., the maximum X-axis value 3000., and MJRX were 1, then the major division points would be 3., 30., 300., and 3000. ✨ And if MNRX(Y).LE.10, there are nine minor divisions inside each major division. like, between 3. and 30. there'd be minor division points at 6., 9., 12., . . . 27. But if MNRX(Y).GT.10., the minor divisions are just omitted. gone. not invited. πŸ™ˆ
  • XINT and YINT β€” input expressions of type REAL, and they're the user coordinates of the point where the two axes cross paths. the meet-cute. the intersection. 🫢
  • IXLB β€” an input expression of type INTEGER, defined like this:
    • IXLB = -1 implies that no X axis is to be drawn.
    • IXLB = 0 implies that the X axis is to be drawn unlabeled.
    • IXLB = 1 implies that the X axis is to be drawn and labeled. ✨
  • IYLB β€” an input expression of type INTEGER, defined like this:
    • IYLB = -1 implies that no Y axis is to be drawn.
    • IYLB = 0 implies that the Y axis is to be drawn unlabeled.
    • IYLB = 1 implies that the Y axis is to be drawn and labeled. ✨

🧚 C-BINDING DESCRIPTION

The C-binding argument descriptions are the same as the FORTRAN argument descriptions. same energy, different syntax, we stay consistent πŸ’œ


πŸ”₯ USAGE

The statement

CALL HALFAX (MJRX,MNRX,MJRY,MNRY,XINT,YINT,IXLB,IYLB)

is equivalent to

CALL GRIDAL (MJRX,MNRX,MJRY,MNRY,IXLB,IYLB,10,XINT,YINT)

so like… HALFAX is basically GRIDAL with the 10 already baked in. main character with a preset. periodt πŸ‘‘


🌟 EXAMPLES

Use the ncargex command to see the following relevant example: tgrida. go look, it's cute, it's iconic, it'll click πŸŽ€


πŸ”‘ ACCESS

To use HALFAX or c_halfax, load the NCAR Graphics libraries ncarg, ncarg_gks, and ncarg_c β€” preferably in that order. order matters bestie, don't fight it πŸ’…


πŸ‘€ SEE ALSO

  • Online: gridall, gacolr, gagetc, gageti, gagetr, gasetc, gaseti, gasetr, grid, gridal, gridl, labmod, perim, periml, tick4, ticks, ncarg_cbind.
  • Hardcopy: NCAR Graphics Fundamentals, UNIX Version

Copyright (C) 1987-2009
University Corporation for Atmospheric Research
The use of this Software is governed by a License Agreement.

ok so that's the whole page, no cap, every single argument and default accounted for 🫢 go draw those axes, bestie, you're gonna ate πŸ’–

and that's a wrap on the HALFAX(3NCARG) page from the UNIX manual, dated March 1993 β€” vintage but still serving ✨

πŸ“¦ where this page comes from